diff options
author | Campbell Barton <ideasman42@gmail.com> | 2016-03-05 01:09:05 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2016-03-05 01:12:07 +0300 |
commit | acebfbb6669b4f0c546068777c7f11146aad3def (patch) | |
tree | b20db009b21a703a4daa5400dbc72e8196e59a78 /source/blender/editors/space_text/text_draw.c | |
parent | 55137629462d3ca2fb152b56cfe26507bdd2c352 (diff) |
Cleanup: unnecessary comma use
Diffstat (limited to 'source/blender/editors/space_text/text_draw.c')
-rw-r--r-- | source/blender/editors/space_text/text_draw.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/source/blender/editors/space_text/text_draw.c b/source/blender/editors/space_text/text_draw.c index 16087921ab6..9448f6af69f 100644 --- a/source/blender/editors/space_text/text_draw.c +++ b/source/blender/editors/space_text/text_draw.c @@ -1108,8 +1108,13 @@ static void draw_cursor(SpaceText *st, ARegion *ar) vsell = txt_get_span(text->lines.first, text->sell) - st->top + offl; vselc = text_get_char_pos(st, text->sell->line, text->selc) - st->left + offc; - if (vcurc < 0) vcurc = 0; - if (vselc < 0) vselc = 0, hidden = 1; + if (vcurc < 0) { + vcurc = 0; + } + if (vselc < 0) { + vselc = 0; + hidden = 1; + } UI_ThemeColor(TH_SHADE2); x = st->showlinenrs ? TXT_OFFSET + TEXTXLOC : TXT_OFFSET; @@ -1135,11 +1140,16 @@ static void draw_cursor(SpaceText *st, ARegion *ar) } y -= froml * lheight; - glRecti(x + fromc * st->cwidth - 1, y, ar->winx, y - lheight); y -= lheight; - for (i = froml + 1; i < tol; i++) - glRecti(x - 4, y, ar->winx, y - lheight), y -= lheight; - glRecti(x - 4, y, x + toc * st->cwidth, y - lheight); y -= lheight; + glRecti(x + fromc * st->cwidth - 1, y, ar->winx, y - lheight); + y -= lheight; + for (i = froml + 1; i < tol; i++) { + glRecti(x - 4, y, ar->winx, y - lheight); + y -= lheight; + } + + glRecti(x - 4, y, x + toc * st->cwidth, y - lheight); + y -= lheight; } } else { |