Mercurial > ~mikael > mcabber > hg
comparison mcabber/mcabber/hooks.c @ 1801:07e73049f7c5
Replace "urgent" with "attention" in HOOK_POST_MESSAGE_IN
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Sun, 21 Mar 2010 15:10:51 +0100 |
parents | 246c5d359c97 |
children | 48e47198a9db |
comparison
equal
deleted
inserted
replaced
1800:d2747442918a | 1801:07e73049f7c5 |
---|---|
194 guint rtype = ROSTER_TYPE_USER; | 194 guint rtype = ROSTER_TYPE_USER; |
195 char *wmsg = NULL, *bmsg = NULL, *mmsg = NULL; | 195 char *wmsg = NULL, *bmsg = NULL, *mmsg = NULL; |
196 GSList *roster_usr; | 196 GSList *roster_usr; |
197 unsigned mucnicklen = 0; | 197 unsigned mucnicklen = 0; |
198 const char *ename = NULL; | 198 const char *ename = NULL; |
199 gboolean urgent = FALSE; | 199 gboolean attention = FALSE; |
200 | 200 |
201 if (encrypted == ENCRYPTED_PGP) | 201 if (encrypted == ENCRYPTED_PGP) |
202 message_flags |= HBB_PREFIX_PGPCRYPT; | 202 message_flags |= HBB_PREFIX_PGPCRYPT; |
203 else if (encrypted == ENCRYPTED_OTR) | 203 else if (encrypted == ENCRYPTED_OTR) |
204 message_flags |= HBB_PREFIX_OTRCRYPT; | 204 message_flags |= HBB_PREFIX_OTRCRYPT; |
311 // Check left boundary | 311 // Check left boundary |
312 if (leftb && (iswalnum(get_char(leftb)) || get_char(leftb) == '_')) | 312 if (leftb && (iswalnum(get_char(leftb)) || get_char(leftb) == '_')) |
313 continue; | 313 continue; |
314 // Check right boundary | 314 // Check right boundary |
315 if (!iswalnum(get_char(rightb)) && get_char(rightb) != '_') | 315 if (!iswalnum(get_char(rightb)) && get_char(rightb) != '_') |
316 urgent = TRUE; | 316 attention = TRUE; |
317 if (urgent && !settings_opt_get_int("muc_disable_nick_hl")) | 317 if (attention && !settings_opt_get_int("muc_disable_nick_hl")) |
318 message_flags |= HBB_PREFIX_HLIGHT; | 318 message_flags |= HBB_PREFIX_HLIGHT; |
319 } | 319 } |
320 } | 320 } |
321 } | 321 } |
322 } | 322 } |
362 hk_arg_t args[] = { | 362 hk_arg_t args[] = { |
363 { "jid", bjid }, | 363 { "jid", bjid }, |
364 { "resource", resname }, | 364 { "resource", resname }, |
365 { "message", wmsg }, | 365 { "message", wmsg }, |
366 { "groupchat", is_groupchat ? "true" : "false" }, | 366 { "groupchat", is_groupchat ? "true" : "false" }, |
367 { "urgent", urgent ? "true" : "false" }, | 367 { "attention", attention ? "true" : "false" }, |
368 { NULL, NULL }, | 368 { NULL, NULL }, |
369 }; | 369 }; |
370 hk_run_handlers(HOOK_POST_MESSAGE_IN, args); | 370 hk_run_handlers(HOOK_POST_MESSAGE_IN, args); |
371 } | 371 } |
372 #endif | 372 #endif |