summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2011-08-16 08:15:02 +0200
committerSebastien Helleu <flashcode@flashtux.org>2011-08-16 08:15:02 +0200
commit8f0e0307c5244c3f6bf43debe3930ec1ca433ce7 (patch)
treed1147bc4215efb9c40057126e7f1fad30cf71e88
parent9070021a54231391d8bb23f7304a7a9f8576b851 (diff)
downloadweechat-8f0e0307c5244c3f6bf43debe3930ec1ca433ce7.zip
core: change priority of hook_focus "buffer_nicklist" in core (2000) and irc (1000)
-rw-r--r--src/gui/gui-bar-item.c7
-rw-r--r--src/plugins/irc/irc-bar-item.c2
2 files changed, 6 insertions, 3 deletions
diff --git a/src/gui/gui-bar-item.c b/src/gui/gui-bar-item.c
index 0257e5a43..06ce24f76 100644
--- a/src/gui/gui-bar-item.c
+++ b/src/gui/gui-bar-item.c
@@ -1600,6 +1600,8 @@ gui_bar_item_hook_signal (const char *signal, const char *item)
void
gui_bar_item_init ()
{
+ char name[128];
+
/* input paste */
gui_bar_item_new (NULL,
gui_bar_item_names[GUI_BAR_ITEM_INPUT_PASTE],
@@ -1743,8 +1745,9 @@ gui_bar_item_init ()
gui_bar_item_names[GUI_BAR_ITEM_BUFFER_NICKLIST]);
gui_bar_item_hook_signal ("buffer_switch",
gui_bar_item_names[GUI_BAR_ITEM_BUFFER_NICKLIST]);
- hook_focus (NULL, gui_bar_item_names[GUI_BAR_ITEM_BUFFER_NICKLIST],
- &gui_bar_item_focus_buffer_nicklist, NULL);
+ snprintf (name, sizeof (name), "2000|%s",
+ gui_bar_item_names[GUI_BAR_ITEM_BUFFER_NICKLIST]);
+ hook_focus (NULL, name, &gui_bar_item_focus_buffer_nicklist, NULL);
/* window number */
gui_bar_item_new (NULL,
diff --git a/src/plugins/irc/irc-bar-item.c b/src/plugins/irc/irc-bar-item.c
index 9625b3cfa..633db73c8 100644
--- a/src/plugins/irc/irc-bar-item.c
+++ b/src/plugins/irc/irc-bar-item.c
@@ -554,6 +554,6 @@ irc_bar_item_init ()
weechat_bar_item_new ("irc_channel", &irc_bar_item_channel, NULL);
weechat_bar_item_new ("lag", &irc_bar_item_lag, NULL);
weechat_bar_item_new ("input_prompt", &irc_bar_item_input_prompt, NULL);
- weechat_hook_focus ("500|buffer_nicklist",
+ weechat_hook_focus ("buffer_nicklist",
&irc_bar_item_focus_buffer_nicklist, NULL);
}