From 1dd535da5dc04852de48555fe222eb17881c48c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Mon, 30 Oct 2023 23:41:28 +0100 Subject: trigger: rename local variable "trigger_filter" to "filter" on monitor buffer (closes #2037) --- src/plugins/trigger/trigger-buffer.c | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) (limited to 'src/plugins') diff --git a/src/plugins/trigger/trigger-buffer.c b/src/plugins/trigger/trigger-buffer.c index 346234147..3ca397a96 100644 --- a/src/plugins/trigger/trigger-buffer.c +++ b/src/plugins/trigger/trigger-buffer.c @@ -110,7 +110,7 @@ trigger_buffer_set_title () const char *ptr_filter; char title[1024]; - ptr_filter = weechat_buffer_get_string (trigger_buffer, "localvar_trigger_filter"); + ptr_filter = weechat_buffer_get_string (trigger_buffer, "localvar_filter"); snprintf (title, sizeof (title), _("Trigger monitor (filter: %s) | Input: q=close, words=filter"), (ptr_filter) ? ptr_filter : "*"); @@ -140,11 +140,11 @@ trigger_buffer_input_cb (const void *pointer, void *data, /* set filters */ if (strcmp (input_data, "*") == 0) - weechat_buffer_set (buffer, "localvar_del_trigger_filter", ""); + weechat_buffer_set (buffer, "localvar_del_filter", ""); else - weechat_buffer_set (buffer, "localvar_set_trigger_filter", input_data); + weechat_buffer_set (buffer, "localvar_set_filter", input_data); trigger_buffer_set_filter (weechat_buffer_get_string (buffer, - "localvar_trigger_filter")); + "localvar_filter")); trigger_buffer_set_title (); return WEECHAT_RC_OK; @@ -188,7 +188,7 @@ trigger_buffer_set_callbacks () weechat_buffer_set_pointer (trigger_buffer, "input_callback", &trigger_buffer_input_cb); trigger_buffer_set_filter (weechat_buffer_get_string (trigger_buffer, - "localvar_trigger_filter")); + "localvar_filter")); } } @@ -240,15 +240,9 @@ trigger_buffer_open (const char *filter, int switch_to_buffer) } if (filter && filter[0]) - { - weechat_buffer_set (trigger_buffer, - "localvar_set_trigger_filter", filter); - } + weechat_buffer_set (trigger_buffer, "localvar_set_filter", filter); else - { - weechat_buffer_set (trigger_buffer, - "localvar_del_trigger_filter", ""); - } + weechat_buffer_set (trigger_buffer, "localvar_del_filter", ""); trigger_buffer_set_filter (filter); trigger_buffer_set_title (); -- cgit v1.2.3