diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2008-09-02 10:38:06 +0200 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2008-09-02 10:38:06 +0200 |
commit | 1b726d3c71316a93e461374543e58d9907e9c714 (patch) | |
tree | 28b645c8a8774441456744c8f806faa3ea05c14a /src/gui | |
parent | aca489be938618b887e40020742440d18b102d34 (diff) | |
download | weechat-1b726d3c71316a93e461374543e58d9907e9c714.zip |
Fix refresh bug with bars when items are empty and size is zero (auto)
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/curses/gui-curses-bar.c | 7 | ||||
-rw-r--r-- | src/gui/curses/gui-curses-main.c | 3 | ||||
-rw-r--r-- | src/gui/curses/gui-curses-window.c | 2 |
3 files changed, 8 insertions, 4 deletions
diff --git a/src/gui/curses/gui-curses-bar.c b/src/gui/curses/gui-curses-bar.c index 3d2027480..96d150f63 100644 --- a/src/gui/curses/gui-curses-bar.c +++ b/src/gui/curses/gui-curses-bar.c @@ -1022,8 +1022,11 @@ gui_bar_window_draw (struct t_gui_bar_window *bar_window, } else { - gui_bar_window_set_current_size (bar_window->bar, 1); - gui_bar_window_recreate_bar_windows (bar_window->bar); + if (gui_bar_window_get_current_size (bar_window) != 1) + { + gui_bar_window_set_current_size (bar_window->bar, 1); + gui_bar_window_recreate_bar_windows (bar_window->bar); + } gui_window_clear (bar_window->win_bar, CONFIG_COLOR(bar_window->bar->color_bg)); } diff --git a/src/gui/curses/gui-curses-main.c b/src/gui/curses/gui-curses-main.c index f76c7ae09..0e193e793 100644 --- a/src/gui/curses/gui-curses-main.c +++ b/src/gui/curses/gui-curses-main.c @@ -295,7 +295,10 @@ gui_main_loop () /* refresh window if needed */ if (gui_window_refresh_needed) + { gui_window_refresh_screen (); + gui_window_refresh_needed = 0; + } /* wait for keyboard or network activity */ FD_ZERO (&read_fds); diff --git a/src/gui/curses/gui-curses-window.c b/src/gui/curses/gui-curses-window.c index 8ec06f180..9d1cc58b2 100644 --- a/src/gui/curses/gui-curses-window.c +++ b/src/gui/curses/gui-curses-window.c @@ -1682,8 +1682,6 @@ gui_window_refresh_screen () refresh (); gui_window_refresh_windows (); } - - gui_window_refresh_needed = 0; } /* |