aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Fleischer <lfleischer@calcurse.org>2016-10-30 11:42:24 +0100
committerLukas Fleischer <lfleischer@calcurse.org>2016-10-30 11:57:01 +0100
commitfd97187bcddd836bed26ee499f2a6d6b4af0ba29 (patch)
tree4bc2d2e556ca9b58c30dbb56f18823df0004aaa4
parentcf75caeb612ac9b3a1fadf8a63c1632c941d2655 (diff)
downloadcalcurse-fd97187bcddd836bed26ee499f2a6d6b4af0ba29.tar.gz
calcurse-fd97187bcddd836bed26ee499f2a6d6b4af0ba29.zip
Fix visible region after loading list box items
Make sure the visible region is updated after loading items, e.g. when the users switches from the full todo list to the "uncompleted items only" view. Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
-rw-r--r--src/listbox.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/listbox.c b/src/listbox.c
index 94c07ba..dad249c 100644
--- a/src/listbox.c
+++ b/src/listbox.c
@@ -126,6 +126,7 @@ void listbox_load_items(struct listbox *lb, int item_count)
else if (lb->item_sel >= item_count)
lb->item_sel = item_count - 1;
listbox_fix_sel(lb, 1);
+ listbox_fix_visible_region(lb);
}
void listbox_draw_deco(struct listbox *lb, int hilt)