]> git.0d.be Git - empathy.git/blobdiff - libempathy-gtk/empathy-linking-dialog.c
individual_view_drag_end: remove the auto scroll
[empathy.git] / libempathy-gtk / empathy-linking-dialog.c
index e6d408fb454e7666a265cabbe1ae741168334423..350bfdc22622f51543e76b33d6a99520265fc717 100644 (file)
@@ -159,7 +159,7 @@ linking_response_cb (EmpathyLinkingDialog *self,
   if (response == GTK_RESPONSE_OK)
     {
       EmpathyIndividualManager *manager;
-      GList *personas;
+      GeeSet *personas;
 
       manager = empathy_individual_manager_dup_singleton ();
 
@@ -181,7 +181,7 @@ linking_response_cb (EmpathyLinkingDialog *self,
       dialog = gtk_message_dialog_new (GTK_WINDOW (self), GTK_DIALOG_MODAL,
           GTK_MESSAGE_WARNING, GTK_BUTTONS_NONE,
           _("Unlink linked contacts '%s'?"),
-          folks_aliasable_get_alias (FOLKS_ALIASABLE (individual)));
+          folks_alias_details_get_alias (FOLKS_ALIAS_DETAILS (individual)));
       gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog),
           _("Are you sure you want to unlink these linked contacts? This will "
             "completely split the linked contacts into separate contacts."));
@@ -223,7 +223,8 @@ empathy_linking_dialog_show (FolksIndividual *individual,
     GtkWindow *parent)
 {
   EmpathyLinkingDialogPriv *priv;
-  GList *personas, *l;
+  GeeSet *personas;
+  GeeIterator *iter;
   guint num_personas = 0;
 
   /* Create the dialogue if it doesn't exist */
@@ -246,11 +247,16 @@ empathy_linking_dialog_show (FolksIndividual *individual,
   /* Count how many Telepathy personas we have, to see whether we can
    * unlink */
   personas = folks_individual_get_personas (individual);
-  for (l = personas; l != NULL; l = l->next)
+  iter = gee_iterable_iterator (GEE_ITERABLE (personas));
+  while (gee_iterator_next (iter))
     {
-      if (TPF_IS_PERSONA (l->data))
+      FolksPersona *persona = gee_iterator_get (iter);
+      if (empathy_folks_persona_is_interesting (persona))
         num_personas++;
+
+      g_clear_object (&persona);
     }
+  g_clear_object (&iter);
 
   /* Only make the "Unlink" button sensitive if we have enough personas */
   gtk_dialog_set_response_sensitive (GTK_DIALOG (linking_dialog),