diff options
author | Philip Withnall <philip.withnall@collabora.co.uk> | 2010-12-13 02:51:07 +0800 |
---|---|---|
committer | Philip Withnall <philip.withnall@collabora.co.uk> | 2010-12-14 00:58:50 +0800 |
commit | c6371ec63c928c848cbb5474cb005af5cc414230 (patch) | |
tree | 7c1f174c6e11a64bbe30a77fa7226e7aef36f133 /libempathy-gtk/empathy-individual-widget.c | |
parent | 92ab34517a94d36ced95514e4fdbde17b2e6004f (diff) | |
download | gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar.gz gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar.bz2 gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar.lz gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar.xz gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.tar.zst gsoc2013-empathy-c6371ec63c928c848cbb5474cb005af5cc414230.zip |
Bug 637097 — Port to latest folks API changes
Catch up with three interface renamings which have happened in folks master.
This bumps Empathy's folks dependency to 0.3.3. Closes: bgo#637097
Diffstat (limited to 'libempathy-gtk/empathy-individual-widget.c')
-rw-r--r-- | libempathy-gtk/empathy-individual-widget.c | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/libempathy-gtk/empathy-individual-widget.c b/libempathy-gtk/empathy-individual-widget.c index 138b70db9..44e7f9572 100644 --- a/libempathy-gtk/empathy-individual-widget.c +++ b/libempathy-gtk/empathy-individual-widget.c @@ -220,19 +220,20 @@ update_weak_contact (EmpathyIndividualWidget *self) personas = folks_individual_get_personas (priv->individual); for (l = personas; l != NULL; l = l->next) { - FolksPresence *presence; + FolksHasPresence *presence; /* We only want personas which implement FolksPresence */ - if (!FOLKS_IS_PRESENCE (l->data)) + if (!FOLKS_IS_HAS_PRESENCE (l->data)) continue; - presence = FOLKS_PRESENCE (l->data); + presence = FOLKS_HAS_PRESENCE (l->data); - if (folks_presence_typecmp (folks_presence_get_presence_type (presence), + if (folks_has_presence_typecmp ( + folks_has_presence_get_presence_type (presence), presence_type) > 0 && TPF_IS_PERSONA (presence)) { - presence_type = folks_presence_get_presence_type (presence); + presence_type = folks_has_presence_get_presence_type (presence); tp_contact = tpf_persona_get_contact (TPF_PERSONA (l->data)); } } @@ -896,7 +897,7 @@ individual_dup_avatar (FolksIndividual *individual) /* FIXME: We just choose the first Persona which has an avatar, and save that. * The avatar handling in EmpathyContact needs to be moved into libfolks as - * much as possible, and this code rewritten to use FolksAvatar. + * much as possible, and this code rewritten to use FolksHasAvatar. * (bgo#627401) */ personas = folks_individual_get_personas (individual); for (l = personas; l != NULL; l = l->next) @@ -1150,8 +1151,8 @@ favourite_toggled_cb (GtkToggleButton *button, EmpathyIndividualWidget *self) { gboolean active = gtk_toggle_button_get_active (button); - folks_favourite_set_is_favourite ( - FOLKS_FAVOURITE (GET_PRIV (self)->individual), active); + folks_favouritable_set_is_favourite ( + FOLKS_FAVOURITABLE (GET_PRIV (self)->individual), active); } static void @@ -1247,11 +1248,13 @@ notify_presence_cb (gpointer folks_object, state_image = g_object_get_data (table, "state-image"); /* FIXME: Default messages should be moved into libfolks (bgo#627403) */ - message = folks_presence_get_presence_message (FOLKS_PRESENCE (folks_object)); + message = folks_has_presence_get_presence_message ( + FOLKS_HAS_PRESENCE (folks_object)); if (EMP_STR_EMPTY (message)) { message = empathy_presence_get_default_message ( - folks_presence_get_presence_type (FOLKS_PRESENCE (folks_object))); + folks_has_presence_get_presence_type ( + FOLKS_HAS_PRESENCE (folks_object))); } if (message != NULL) @@ -1261,7 +1264,8 @@ notify_presence_cb (gpointer folks_object, gtk_image_set_from_icon_name (GTK_IMAGE (state_image), empathy_icon_name_for_presence ( - folks_presence_get_presence_type (FOLKS_PRESENCE (folks_object))), + folks_has_presence_get_presence_type ( + FOLKS_HAS_PRESENCE (folks_object))), GTK_ICON_SIZE_BUTTON); gtk_widget_show (state_image); } @@ -1290,7 +1294,8 @@ notify_is_favourite_cb (gpointer folks_object, if (GTK_IS_TOGGLE_BUTTON (favourite_widget)) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (favourite_widget), - folks_favourite_get_is_favourite (FOLKS_FAVOURITE (folks_object))); + folks_favouritable_get_is_favourite ( + FOLKS_FAVOURITABLE (folks_object))); } } |