diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2009-06-13 16:27:04 +0200 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2009-06-13 16:27:04 +0200 |
commit | 40e3422058347e399e7a8ad4f13c21529fff49fb (patch) | |
tree | 64b0a0531860f6b508eb3201958ddf1b9e53d24f /src | |
parent | 178664655046777374e0521f19e15a794d37fd63 (diff) | |
download | weechat-40e3422058347e399e7a8ad4f13c21529fff49fb.zip |
Do not refresh buffer if displayed line is filtered (hidden)
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/gui-chat.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/gui/gui-chat.c b/src/gui/gui-chat.c index 31b452e8b..4b0f9ca28 100644 --- a/src/gui/gui-chat.c +++ b/src/gui/gui-chat.c @@ -468,9 +468,6 @@ gui_chat_printf_date_tags (struct t_gui_buffer *buffer, time_t date, if (date <= 0) date = date_printed; - if (gui_init_ok) - ptr_line = buffer->lines->last_line; - at_least_one_message_printed = 0; pos = gui_chat_buffer; @@ -540,14 +537,16 @@ gui_chat_printf_date_tags (struct t_gui_buffer *buffer, time_t date, if (gui_init_ok) { - gui_line_add (buffer, (display_time) ? date : 0, - (display_time) ? date_printed : 0, - tags, pos_prefix, ptr_msg); - if (buffer->lines->last_line && buffer->print_hooks_enabled) + ptr_line = gui_line_add (buffer, (display_time) ? date : 0, + (display_time) ? date_printed : 0, + tags, pos_prefix, ptr_msg); + if (ptr_line) { - hook_print_exec (buffer, buffer->lines->last_line); + if (buffer->print_hooks_enabled) + hook_print_exec (buffer, ptr_line); + if (ptr_line->data->displayed) + at_least_one_message_printed = 1; } - at_least_one_message_printed = 1; } else { |