--- a/mcabber/src/jabglue.c Wed May 31 20:32:27 2006 +0200
+++ b/mcabber/src/jabglue.c Wed May 31 23:12:56 2006 +0200
@@ -1200,7 +1200,7 @@
buddy_setinsideroom(room_elt->data, TRUE);
// Set the message flag unless we're already in the room buffer window
- scr_setmsgflag_if_needed(roomjid);
+ scr_setmsgflag_if_needed(roomjid, FALSE);
// Add a message to the tracelog file
mbuf = g_strdup_printf("You have joined %s as \"%s\"", roomjid, ournick);
scr_LogPrint(LPRINT_LOGNORM, "%s", mbuf);
--- a/mcabber/src/screen.c Wed May 31 20:32:27 2006 +0200
+++ b/mcabber/src/screen.c Wed May 31 23:12:56 2006 +0200
@@ -1770,28 +1770,29 @@
// scr_setmsgflag_if_needed(jid)
// Set the message flag unless we're already in the jid buffer window
-void scr_setmsgflag_if_needed(const char *jid)
+void scr_setmsgflag_if_needed(const char *jid, int special)
{
- const char *current_jid;
+ const char *current_id;
bool iscurrentlocked = FALSE;
- guint isspe = FALSE;
if (!jid)
return;
if (current_buddy) {
- isspe = buddy_gettype(BUDDATA(current_buddy)) & ROSTER_TYPE_SPECIAL;
- current_jid = buddy_getjid(BUDDATA(current_buddy));
- if (current_jid) {
- winbuf *win_entry = scr_SearchWindow(current_jid, isspe);
+ if (special)
+ current_id = buddy_getname(BUDDATA(current_buddy));
+ else
+ current_id = buddy_getjid(BUDDATA(current_buddy));
+ if (current_id) {
+ winbuf *win_entry = scr_SearchWindow(current_id, special);
if (!win_entry) return;
iscurrentlocked = win_entry->lock;
}
} else {
- current_jid = NULL;
+ current_id = NULL;
}
- if (!chatmode || !current_jid || strcmp(jid, current_jid) || iscurrentlocked)
- roster_msg_setflag(jid, isspe, TRUE);
+ if (!chatmode || !current_id || strcmp(jid, current_id) || iscurrentlocked)
+ roster_msg_setflag(jid, special, TRUE);
}
// scr_set_multimode()
--- a/mcabber/src/screen.h Wed May 31 20:32:27 2006 +0200
+++ b/mcabber/src/screen.h Wed May 31 23:12:56 2006 +0200
@@ -71,7 +71,7 @@
inline void scr_set_chatmode(int enable);
inline void scr_set_multimode(int enable, char *subject);
inline int scr_get_multimode(void);
-void scr_setmsgflag_if_needed(const char *jid);
+void scr_setmsgflag_if_needed(const char *jid, int special);
void scr_append_multiline(const char *line);
inline const char *scr_get_multiline(void);
inline const char *scr_get_multimode_subj(void);