diff options
author | Lars Henriksen <LarsHenriksen@get2net.dk> | 2017-12-17 08:25:10 +0100 |
---|---|---|
committer | Lukas Fleischer <lfleischer@calcurse.org> | 2018-05-26 11:31:43 +0200 |
commit | bb7381765c435ac37e133f7fcc14a07823539050 (patch) | |
tree | f0902c3c714dca97607000e464b52df37aa44e01 /src/wins.c | |
parent | a5cc46cd550b335b0de6ce7658e0c1ca5068255e (diff) | |
download | calcurse-bb7381765c435ac37e133f7fcc14a07823539050.tar.gz calcurse-bb7381765c435ac37e133f7fcc14a07823539050.zip |
Scrollbar and right window border (corrected)
When a scrollbar is on display in APP or TOD windows, the right
vertical border (outside the scrollbar) is not highlighted
when the window is selected.
The scrollbar is always highlighted:
- when APP or TOD is deselected
- in configuration windows where borders otherwise are not
The patch moves the scrollbar parameters (except highlight)
from arguments of draw_scrollbar() to the function itself.
The highlight argument was 1; instead it is set higher in
the call hierarchy (wins_update_panels()) and passed on down.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
Diffstat (limited to 'src/wins.c')
-rw-r--r-- | src/wins.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -355,7 +355,7 @@ void wins_scrollwin_draw_deco(struct scrollwin *sw, int hilt) } /* Display a scrolling window. */ -void wins_scrollwin_display(struct scrollwin *sw) +void wins_scrollwin_display(struct scrollwin *sw, int hilt) { int inner_y = sw->y + (conf.compact_panels ? 1 : 3); int inner_x = sw->x + 1; @@ -363,7 +363,7 @@ void wins_scrollwin_display(struct scrollwin *sw) int inner_w = sw->w - 2; if (sw->line_num > inner_h) - draw_scrollbar(sw); + draw_scrollbar(sw, hilt); wmove(win[STA].p, 0, 0); wnoutrefresh(sw->win); /* @@ -547,9 +547,9 @@ void wins_update_border(int flags) void wins_update_panels(int flags) { if (flags & FLAG_APP) - ui_day_update_panel(slctd_win); + ui_day_update_panel(slctd_win == APP); if (flags & FLAG_TOD) - ui_todo_update_panel(slctd_win); + ui_todo_update_panel(slctd_win == TOD); if (flags & FLAG_CAL) ui_calendar_update_panel(); } |