Mercurial > pidgin.yaz
comparison libgaim/protocols/jabber/buddy.c @ 14463:7df4ab213577
[gaim-migrate @ 17177]
commit part of 1547648
commit some jabber stuff I did a few days ago and forgot about
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Wed, 06 Sep 2006 03:58:53 +0000 |
parents | 60b1bc8dbf37 |
children | f23506e8f812 |
comparison
equal
deleted
inserted
replaced
14462:34a5709ff951 | 14463:7df4ab213577 |
---|---|
656 jbr = resources->data; | 656 jbr = resources->data; |
657 if(jbr->status) | 657 if(jbr->status) |
658 purdy = gaim_strdup_withhtml(jbr->status); | 658 purdy = gaim_strdup_withhtml(jbr->status); |
659 g_string_append_printf(info_text, "<b>%s:</b> %s<br/>", | 659 g_string_append_printf(info_text, "<b>%s:</b> %s<br/>", |
660 _("Resource"), jbr->name); | 660 _("Resource"), jbr->name); |
661 g_string_append_printf(info_text, "<b>%s:</b> %d<br/>", | |
662 _("Priority"), jbr->priority); | |
661 g_string_append_printf(info_text, "<b>%s:</b> %s%s%s<br/>", | 663 g_string_append_printf(info_text, "<b>%s:</b> %s%s%s<br/>", |
662 _("Status"), jabber_buddy_state_get_name(jbr->state), | 664 _("Status"), jabber_buddy_state_get_name(jbr->state), |
663 purdy ? ": " : "", | 665 purdy ? ": " : "", |
664 purdy ? purdy : ""); | 666 purdy ? purdy : ""); |
665 if(purdy) | 667 if(purdy) |
1188 GaimAccount *account; | 1190 GaimAccount *account; |
1189 GaimStatus *status; | 1191 GaimStatus *status; |
1190 JabberBuddy *jb = jabber_buddy_find(js, who, TRUE); | 1192 JabberBuddy *jb = jabber_buddy_find(js, who, TRUE); |
1191 xmlnode *presence; | 1193 xmlnode *presence; |
1192 JabberBuddyState state; | 1194 JabberBuddyState state; |
1193 const char *msg; | 1195 char *msg; |
1194 int priority; | 1196 int priority; |
1195 | 1197 |
1196 account = gaim_connection_get_account(js->gc); | 1198 account = gaim_connection_get_account(js->gc); |
1197 gpresence = gaim_account_get_presence(account); | 1199 gpresence = gaim_account_get_presence(account); |
1198 status = gaim_presence_get_active_status(gpresence); | 1200 status = gaim_presence_get_active_status(gpresence); |
1199 | 1201 |
1200 gaim_status_to_jabber(status, &state, &msg, &priority); | 1202 gaim_status_to_jabber(status, &state, &msg, &priority); |
1201 presence = jabber_presence_create(state, msg, priority); | 1203 presence = jabber_presence_create(state, msg, priority); |
1204 | |
1205 g_free(msg); | |
1202 | 1206 |
1203 xmlnode_set_attrib(presence, "to", who); | 1207 xmlnode_set_attrib(presence, "to", who); |
1204 if(invisible) { | 1208 if(invisible) { |
1205 xmlnode_set_attrib(presence, "type", "invisible"); | 1209 xmlnode_set_attrib(presence, "type", "invisible"); |
1206 jb->invisible |= JABBER_INVIS_BUDDY; | 1210 jb->invisible |= JABBER_INVIS_BUDDY; |