summaryrefslogtreecommitdiff
path: root/src/gui/gui-input.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2013-11-09 13:21:56 +0100
committerSebastien Helleu <flashcode@flashtux.org>2013-11-09 13:21:56 +0100
commit9b4eb6d60766300c6f1ae9503b283a45d07f1d4c (patch)
treef59491db3341c8f6d0fb50f3c39abd39f0781ed8 /src/gui/gui-input.c
parent2b049723262b3f1247575f75c8a698e646458db0 (diff)
downloadweechat-9b4eb6d60766300c6f1ae9503b283a45d07f1d4c.zip
core: add bar item "buffer_zoom", add signals "buffer_{zoomed|unzoomed}" (patch #8204) (patch from Nils Görs)
Diffstat (limited to 'src/gui/gui-input.c')
-rw-r--r--src/gui/gui-input.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/gui-input.c b/src/gui/gui-input.c
index a97f485f7..708e31e92 100644
--- a/src/gui/gui-input.c
+++ b/src/gui/gui-input.c
@@ -1605,11 +1605,14 @@ void
gui_input_zoom_merged_buffer (struct t_gui_buffer *buffer)
{
struct t_gui_window *ptr_window;
+ int buffer_was_zoomed;
/* do nothing if current buffer is not merged with another buffer */
if (gui_buffer_count_merged_buffers (buffer->number) < 2)
return;
+ buffer_was_zoomed = (buffer->active == 2);
+
/* reset scroll in all windows displaying this buffer number */
for (ptr_window = gui_windows; ptr_window;
ptr_window = ptr_window->next_window)
@@ -1646,6 +1649,9 @@ gui_input_zoom_merged_buffer (struct t_gui_buffer *buffer)
}
gui_buffer_ask_chat_refresh (buffer, 2);
+
+ hook_signal_send ((buffer_was_zoomed) ? "buffer_unzoomed" : "buffer_zoomed",
+ WEECHAT_HOOK_SIGNAL_POINTER, buffer);
}
/*