]> git.0d.be Git - empathy.git/commitdiff
Fix urgency hint for MUCs
authorXavier Claessens <xclaesse@gmail.com>
Fri, 17 Apr 2009 12:50:06 +0000 (14:50 +0200)
committerXavier Claessens <xclaesse@gmail.com>
Fri, 17 Apr 2009 13:09:31 +0000 (15:09 +0200)
src/empathy-chat-window.c

index e6823344e57b01aa1862ea340694a37d4f07ed86..145d45e7fac5f98dcf97c9dfd37ae6a3f84f9784 100644 (file)
@@ -954,7 +954,13 @@ chat_window_new_message_cb (EmpathyChat       *chat,
                return;
        }
        
-       if (empathy_chat_get_members_count (chat) > 2) {
+       /* If empathy_chat_is_room() returns TRUE, that means it's a named MUC.
+        * If empathy_chat_get_remote_contact() returns NULL, that means it's
+        * an unamed MUC (msn-like).
+        * In case of a MUC, we set urgency only if the message contains our
+        * alias. */
+       if (empathy_chat_is_room (chat) ||
+           empathy_chat_get_remote_contact (chat) == NULL) {
                needs_urgency = empathy_message_should_highlight (message);
        } else {
                needs_urgency = TRUE;