diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | src/gui/gui-buffer.c | 15 | ||||
-rw-r--r-- | weechat/ChangeLog | 4 | ||||
-rw-r--r-- | weechat/src/gui/gui-buffer.c | 15 |
4 files changed, 22 insertions, 16 deletions
@@ -1,10 +1,12 @@ WeeChat - Wee Enhanced Environment for Chat =========================================== -ChangeLog - 2007-03-05 +ChangeLog - 2007-03-06 Version 0.2.4 (under dev!): + * fixed bug with server buffer when "look_one_server_buffer" is ON and + server buffer is moved to any number > 1 (bug #19219) * fixed /help command: displays plugin help for redefined commands (bug #19166) * prefix '/' disabled in commands (patch #5769) diff --git a/src/gui/gui-buffer.c b/src/gui/gui-buffer.c index b9243df59..423a70f3a 100644 --- a/src/gui/gui-buffer.c +++ b/src/gui/gui-buffer.c @@ -94,7 +94,7 @@ gui_buffer_new (t_gui_window *window, void *server, void *channel, int type, weechat_log_printf ("Creating new buffer\n"); #endif - /* use first buffer if no server was assigned to this buffer */ + /* use first buffer if no server is assigned to this buffer */ if ((type == BUFFER_TYPE_STANDARD) && gui_buffers && (!SERVER(gui_buffers)) && (!channel)) { @@ -111,19 +111,20 @@ gui_buffer_new (t_gui_window *window, void *server, void *channel, int type, gui_buffers->completion.server = server; return gui_buffers; } - + + /* use "all servers" buffer if found */ if (cfg_look_one_server_buffer && (type == BUFFER_TYPE_STANDARD) && gui_buffers && server && !channel) { ptr_buffer = gui_buffer_servers_search (); if (ptr_buffer) { - ((t_irc_server *)(server))->buffer = gui_buffers; - gui_buffers->server = server; + ((t_irc_server *)(server))->buffer = ptr_buffer; + ptr_buffer->server = server; if (switch_to_buffer) - gui_window_switch_to_buffer (window, gui_buffers); - gui_window_redraw_buffer (gui_buffers); - return gui_buffers; + gui_window_switch_to_buffer (window, ptr_buffer); + gui_window_redraw_buffer (ptr_buffer); + return ptr_buffer; } } diff --git a/weechat/ChangeLog b/weechat/ChangeLog index 7e00ad446..2f70c5a91 100644 --- a/weechat/ChangeLog +++ b/weechat/ChangeLog @@ -1,10 +1,12 @@ WeeChat - Wee Enhanced Environment for Chat =========================================== -ChangeLog - 2007-03-05 +ChangeLog - 2007-03-06 Version 0.2.4 (under dev!): + * fixed bug with server buffer when "look_one_server_buffer" is ON and + server buffer is moved to any number > 1 (bug #19219) * fixed /help command: displays plugin help for redefined commands (bug #19166) * prefix '/' disabled in commands (patch #5769) diff --git a/weechat/src/gui/gui-buffer.c b/weechat/src/gui/gui-buffer.c index b9243df59..423a70f3a 100644 --- a/weechat/src/gui/gui-buffer.c +++ b/weechat/src/gui/gui-buffer.c @@ -94,7 +94,7 @@ gui_buffer_new (t_gui_window *window, void *server, void *channel, int type, weechat_log_printf ("Creating new buffer\n"); #endif - /* use first buffer if no server was assigned to this buffer */ + /* use first buffer if no server is assigned to this buffer */ if ((type == BUFFER_TYPE_STANDARD) && gui_buffers && (!SERVER(gui_buffers)) && (!channel)) { @@ -111,19 +111,20 @@ gui_buffer_new (t_gui_window *window, void *server, void *channel, int type, gui_buffers->completion.server = server; return gui_buffers; } - + + /* use "all servers" buffer if found */ if (cfg_look_one_server_buffer && (type == BUFFER_TYPE_STANDARD) && gui_buffers && server && !channel) { ptr_buffer = gui_buffer_servers_search (); if (ptr_buffer) { - ((t_irc_server *)(server))->buffer = gui_buffers; - gui_buffers->server = server; + ((t_irc_server *)(server))->buffer = ptr_buffer; + ptr_buffer->server = server; if (switch_to_buffer) - gui_window_switch_to_buffer (window, gui_buffers); - gui_window_redraw_buffer (gui_buffers); - return gui_buffers; + gui_window_switch_to_buffer (window, ptr_buffer); + gui_window_redraw_buffer (ptr_buffer); + return ptr_buffer; } } |