1
0
mirror of https://github.com/weechat/weechat.git synced 2026-07-02 15:53:12 +02:00

buflist: add buflist bar on configuration reload (issue #1618)

This commit is contained in:
Sébastien Helleu
2021-03-14 10:54:44 +01:00
parent 3bdae5b464
commit a4440ba8e5
+24 -2
View File
@@ -69,6 +69,27 @@ char *buflist_config_format_buffer_current_eval = NULL;
char *buflist_config_format_hotlist_eval = NULL;
/*
* Reloads buflist configuration file.
*/
int
buflist_config_reload (const void *pointer, void *data,
struct t_config_file *config_file)
{
int rc;
/* make C compiler happy */
(void) pointer;
(void) data;
rc = weechat_config_reload (config_file);
buflist_add_bar ();
return rc;
}
/*
* Frees the signals hooked for refresh.
*/
@@ -444,8 +465,9 @@ buflist_config_init ()
{
struct t_config_section *ptr_section;
buflist_config_file = weechat_config_new (BUFLIST_CONFIG_NAME,
NULL, NULL, NULL);
buflist_config_file = weechat_config_new (
BUFLIST_CONFIG_NAME,
&buflist_config_reload, NULL, NULL);
if (!buflist_config_file)
return 0;