- if (sh != layout.rows - 1 || sw != SidebarWidth) {
- wresize(layout.sidebar, layout.rows - 1, SidebarWidth);
+ if (sh != LINES - 1 || sw != SidebarWidth) {
+ wresize(sidebar_w, LINES - 1, SidebarWidth);
+ wresize(main_w, LINES - 1, COLS - SidebarWidth);
+ mvwin(main_w, 0, SidebarWidth);