Mercurial > pidgin.yaz
comparison libpurple/protocols/jabber/usermood.c @ 29834:1fb503adb2ae
Move the mood UI for ICQ into Pidgin. It still uses the new request API
stuff, which needs to be replaced. Then it needs to replace the XMPP UI.
author | Richard Laager <rlaager@wiktel.com> |
---|---|
date | Mon, 17 Nov 2008 07:30:43 +0000 |
parents | 432d9176d054 |
children | 086b26f60913 |
comparison
equal
deleted
inserted
replaced
29833:cdd5c6929c52 | 29834:1fb503adb2ae |
---|---|
148 if (newmood != NULL && moodtext != NULL) | 148 if (newmood != NULL && moodtext != NULL) |
149 break; | 149 break; |
150 } | 150 } |
151 } | 151 } |
152 if (newmood != NULL) { | 152 if (newmood != NULL) { |
153 const char *status_id; | 153 purple_prpl_got_user_status(js->gc->account, from, "mood", |
154 JabberBuddyResource *resource = jabber_buddy_find_resource(buddy, NULL); | 154 PURPLE_MOOD_NAME, mood, |
155 if(!resource) { /* huh? */ | 155 PURPLE_MOOD_COMMENT, moodtext, |
156 g_free(moodtext); | 156 NULL); |
157 return; | 157 } else { |
158 } | 158 purple_prpl_got_user_status_deactive(js->gc->account, from, "mood"); |
159 status_id = jabber_buddy_state_get_status_id(resource->state); | |
160 | |
161 purple_prpl_got_user_status(js->gc->account, from, status_id, "mood", _(newmood), "moodtext", moodtext?moodtext:"", NULL); | |
162 } | 159 } |
163 g_free(moodtext); | 160 g_free(moodtext); |
164 } | 161 } |
165 | 162 |
166 void jabber_mood_init(void) { | 163 void jabber_mood_init(void) { |