diff options
Diffstat (limited to 'src/gui/curses')
-rw-r--r-- | src/gui/curses/gui-curses-main.c | 6 | ||||
-rw-r--r-- | src/gui/curses/gui-curses-window.c | 12 |
2 files changed, 11 insertions, 7 deletions
diff --git a/src/gui/curses/gui-curses-main.c b/src/gui/curses/gui-curses-main.c index 3736ed272..d31decd8f 100644 --- a/src/gui/curses/gui-curses-main.c +++ b/src/gui/curses/gui-curses-main.c @@ -234,7 +234,7 @@ gui_main_signal_sigwinch () gui_term_lines = new_height; } - gui_window_refresh_needed = 1; + gui_window_ask_refresh (1); } /* @@ -251,7 +251,7 @@ gui_main_refreshs () /* refresh window if needed */ if (gui_window_refresh_needed) { - gui_window_refresh_screen (); + gui_window_refresh_screen ((gui_window_refresh_needed > 1) ? 1 : 0); gui_window_refresh_needed = 0; } @@ -326,7 +326,7 @@ gui_main_loop () hook_fd_keyboard = hook_fd (NULL, STDIN_FILENO, 1, 0, 0, &gui_keyboard_read_cb, NULL); - gui_window_refresh_needed = 1; + gui_window_ask_refresh (1); while (!weechat_quit) { diff --git a/src/gui/curses/gui-curses-window.c b/src/gui/curses/gui-curses-window.c index 6d7dc0080..125e8560f 100644 --- a/src/gui/curses/gui-curses-window.c +++ b/src/gui/curses/gui-curses-window.c @@ -1073,7 +1073,7 @@ gui_window_resize (struct t_gui_window *window, int percentage) 1) < 0) parent->split_pct = old_split_pct; else - gui_window_refresh_needed = 1; + gui_window_ask_refresh (1); } } @@ -1322,15 +1322,19 @@ gui_window_switch_right (struct t_gui_window *window) /* * gui_window_refresh_screen: called when term size is modified - * force == 1 when Ctrl+L is pressed + * full_refresh == 1 when Ctrl+L is pressed */ void -gui_window_refresh_screen () +gui_window_refresh_screen (int full_refresh) { if (gui_ok) { - refresh (); + if (full_refresh) + { + endwin (); + refresh (); + } gui_window_refresh_windows (); } } |