summaryrefslogtreecommitdiff
path: root/src/fe-common/core
diff options
context:
space:
mode:
authorJari Matilainen <jari.matilainen@gmail.com>2015-09-22 22:39:44 +0200
committerJari Matilainen <jari.matilainen@gmail.com>2015-09-22 22:49:50 +0200
commit5a4be0f4f5f36787e98215d87b88a50a5f7e7e01 (patch)
tree99f65e52d1947c71e4a38c6a1c18d39df28ec0e2 /src/fe-common/core
parent2d69deb0a36516bac9514c6d53a1389b0a4b031a (diff)
downloadirssi-5a4be0f4f5f36787e98215d87b88a50a5f7e7e01.zip
Add new setting to optionally modify behaviour of hilight_nick_matches
Fix indentation Remove unused variables that crept into the nick_match_msg_everywhere function
Diffstat (limited to 'src/fe-common/core')
-rw-r--r--src/fe-common/core/fe-messages.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/fe-common/core/fe-messages.c b/src/fe-common/core/fe-messages.c
index 3bd2b666..d09c1b0b 100644
--- a/src/fe-common/core/fe-messages.c
+++ b/src/fe-common/core/fe-messages.c
@@ -183,7 +183,9 @@ static void sig_message_public(SERVER_REC *server, const char *msg,
nickrec = nicklist_find(chanrec, nick);
for_me = !settings_get_bool("hilight_nick_matches") ? FALSE :
- nick_match_msg(chanrec, msg, server->nick);
+ !settings_get_bool("hilight_nick_matches_everywhere") ?
+ nick_match_msg(chanrec, msg, server->nick) :
+ nick_match_msg_everywhere(chanrec, msg, server->nick);
hilight = for_me ? NULL :
hilight_match_nick(server, target, nick, address, MSGLEVEL_PUBLIC, msg);
color = (hilight == NULL) ? NULL : hilight_get_color(hilight);
@@ -694,6 +696,7 @@ void fe_messages_init(void)
(GCompareFunc) g_direct_equal);
settings_add_bool("lookandfeel", "hilight_nick_matches", TRUE);
+ settings_add_bool("lookandfeel", "hilight_nick_matches_everywhere", FALSE);
settings_add_bool("lookandfeel", "emphasis", TRUE);
settings_add_bool("lookandfeel", "emphasis_replace", FALSE);
settings_add_bool("lookandfeel", "emphasis_multiword", FALSE);