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.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ui/sidebarwidget.c b/src/ui/sidebarwidget.c
index ac119575..8c1bb60d 100644
--- a/src/ui/sidebarwidget.c
+++ b/src/ui/sidebarwidget.c
@@ -699,8 +699,9 @@ static void checkModeButtonLayout_SidebarWidget_(iSidebarWidget *d) {
699} 699}
700 700
701void setWidth_SidebarWidget(iSidebarWidget *d, int width) { 701void setWidth_SidebarWidget(iSidebarWidget *d, int width) {
702 const iBool isFixedWidth = deviceType_App() == phone_AppDeviceType;
702 iWidget *w = as_Widget(d); 703 iWidget *w = as_Widget(d);
703 if (deviceType_App() != phone_AppDeviceType) { /* phone doesn't allow resizing */ 704 if (!isFixedWidth) {
704 /* Even less space if the other sidebar is visible, too. */ 705 /* Even less space if the other sidebar is visible, too. */
705 const int otherWidth = 706 const int otherWidth =
706 width_Widget(findWidget_App(d->side == left_SideBarSide ? "sidebar2" : "sidebar")); 707 width_Widget(findWidget_App(d->side == left_SideBarSide ? "sidebar2" : "sidebar"));
@@ -713,7 +714,7 @@ void setWidth_SidebarWidget(iSidebarWidget *d, int width) {
713 arrange_Widget(findWidget_App("stack")); 714 arrange_Widget(findWidget_App("stack"));
714 checkModeButtonLayout_SidebarWidget_(d); 715 checkModeButtonLayout_SidebarWidget_(d);
715 updateItemHeight_SidebarWidget_(d); 716 updateItemHeight_SidebarWidget_(d);
716 if (!isRefreshPending_App()) { 717 if (!isFixedWidth && !isRefreshPending_App()) {
717 updateSize_DocumentWidget(document_App()); 718 updateSize_DocumentWidget(document_App());
718 invalidate_ListWidget(d->list); 719 invalidate_ListWidget(d->list);
719 } 720 }