summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2013-01-15 19:50:36 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2013-01-15 19:50:36 +0000
commit7a0b3475634642194b256ef3c4a294c72e312a18 (patch)
tree003a61d52a2443c86912da3fa5f09dde9b17d83b
parent0f08d885a048ddfc1a6fe52b88ba410f52d5dbe9 (diff)
downloadnetsurf-7a0b3475634642194b256ef3c4a294c72e312a18.tar.gz
netsurf-7a0b3475634642194b256ef3c4a294c72e312a18.tar.bz2
Add parentheses.
-rw-r--r--desktop/textarea.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/desktop/textarea.c b/desktop/textarea.c
index 185a878d9..00c2ca4bc 100644
--- a/desktop/textarea.c
+++ b/desktop/textarea.c
@@ -1251,9 +1251,9 @@ void textarea_redraw(struct textarea *ta, int x, int y, colour bg,
plot->clip(clip);
- if (ta->sel_end == -1 || ta->sel_start == ta->sel_end &&
+ if ((ta->sel_end == -1 || ta->sel_start == ta->sel_end) &&
ta->caret_pos.char_off >= 0) {
- /* There is no selection; draw caret */
+ /* There is no selection, and caret visible: draw caret */
int caret_y = y - ta->scroll_y + ta->caret_y + text_y_offset;
int caret_height = caret_y + ta->line_height;