mirror of
https://github.com/weechat/weechat.git
synced 2026-07-03 08:13:14 +02:00
trigger: add variable "tg_notify" (notify level of a message, if different from "none")
This commit is contained in:
@@ -97,12 +97,16 @@ trigger_callback_set_tags (struct t_gui_buffer *buffer,
|
||||
else if (strncmp (tags[i], "notify_", 7) == 0)
|
||||
{
|
||||
weechat_hashtable_set (extra_vars, "tg_tag_notify", tags[i] + 7);
|
||||
if (strcmp (tags[i] + 7, "private") == 0)
|
||||
if (strcmp (tags[i] + 7, "none") != 0)
|
||||
{
|
||||
snprintf (str_temp, sizeof (str_temp), "%d",
|
||||
(localvar_type
|
||||
&& (strcmp (localvar_type, "private") == 0)) ? 1 : 0);
|
||||
weechat_hashtable_set (extra_vars, "tg_msg_pv", str_temp);
|
||||
weechat_hashtable_set (extra_vars, "tg_notify", tags[i] + 7);
|
||||
if (strcmp (tags[i] + 7, "private") == 0)
|
||||
{
|
||||
snprintf (str_temp, sizeof (str_temp), "%d",
|
||||
(localvar_type
|
||||
&& (strcmp (localvar_type, "private") == 0)) ? 1 : 0);
|
||||
weechat_hashtable_set (extra_vars, "tg_msg_pv", str_temp);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (strncmp (tags[i], "nick_", 5) == 0)
|
||||
|
||||
Reference in New Issue
Block a user