summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2008-09-02 10:38:06 +0200
committerSebastien Helleu <flashcode@flashtux.org>2008-09-02 10:38:06 +0200
commit1b726d3c71316a93e461374543e58d9907e9c714 (patch)
tree28b645c8a8774441456744c8f806faa3ea05c14a /src/gui
parentaca489be938618b887e40020742440d18b102d34 (diff)
downloadweechat-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.c7
-rw-r--r--src/gui/curses/gui-curses-main.c3
-rw-r--r--src/gui/curses/gui-curses-window.c2
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;
}
/*