Mercurial > pidgin
diff libpurple/prpl.c @ 29345:13fa0fffac6d
merge of '1529fa495883d559527375c0d8b7fbe68cf019c2'
and '3e607deb45a1ba0c62a1b8f376d94b2751ec8343'
author | Paul Aurich <paul@darkrain42.org> |
---|---|
date | Sat, 09 Jan 2010 02:00:18 +0000 |
parents | 31a34388fb1d |
children | a8cc50c2279f |
line wrap: on
line diff
--- a/libpurple/prpl.c Fri Nov 20 00:33:23 2009 +0000 +++ b/libpurple/prpl.c Sat Jan 09 02:00:18 2010 +0000 @@ -595,17 +595,21 @@ while (list) { PurpleBuddy *buddy = list->data; - PurpleMediaCaps oldcaps = buddy->media_caps; + PurpleMediaCaps oldcaps = purple_buddy_get_media_caps(buddy); + PurpleMediaCaps newcaps = 0; const gchar *bname = purple_buddy_get_name(buddy); list = g_slist_delete_link(list, list); - buddy->media_caps = purple_prpl_get_media_caps(account, bname); - if (oldcaps == buddy->media_caps) + + newcaps = purple_prpl_get_media_caps(account, bname); + purple_buddy_set_media_caps(buddy, newcaps); + + if (oldcaps == newcaps) continue; purple_signal_emit(purple_blist_get_handle(), "buddy-caps-changed", buddy, - buddy->media_caps, oldcaps); + newcaps, oldcaps); } #endif }