summaryrefslogtreecommitdiff
path: root/src/ui/sidebarwidget.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/sidebarwidget.c')
-rw-r--r--src/ui/sidebarwidget.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ui/sidebarwidget.c b/src/ui/sidebarwidget.c
index 71b641d4..96c9ebd8 100644
--- a/src/ui/sidebarwidget.c
+++ b/src/ui/sidebarwidget.c
@@ -175,6 +175,7 @@ void setMode_SidebarWidget(iSidebarWidget *d, enum iSidebarMode mode) {
175 } 175 }
176 const float heights[max_SidebarMode] = { 1.333f, 3, 3, 1.2f }; 176 const float heights[max_SidebarMode] = { 1.333f, 3, 3, 1.2f };
177 d->itemHeight = heights[mode] * lineHeight_Text(uiContent_FontId); 177 d->itemHeight = heights[mode] * lineHeight_Text(uiContent_FontId);
178 invalidate_SidebarWidget_(d);
178} 179}
179 180
180enum iSidebarMode mode_SidebarWidget(const iSidebarWidget *d) { 181enum iSidebarMode mode_SidebarWidget(const iSidebarWidget *d) {
@@ -401,6 +402,7 @@ static iBool processEvent_SidebarWidget_(iSidebarWidget *d, const SDL_Event *ev)
401 if (argLabel_Command(cmd, "show") && !isVisible_Widget(w)) { 402 if (argLabel_Command(cmd, "show") && !isVisible_Widget(w)) {
402 postCommand_App("sidebar.toggle"); 403 postCommand_App("sidebar.toggle");
403 } 404 }
405 scroll_SidebarWidget_(d, 0);
404 return iTrue; 406 return iTrue;
405 } 407 }
406 else if (equal_Command(cmd, "sidebar.toggle")) { 408 else if (equal_Command(cmd, "sidebar.toggle")) {