aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxclaesse <xclaesse@4ee84921-47dd-4033-b63a-18d7a039a3e4>2007-10-02 16:59:16 +0800
committerxclaesse <xclaesse@4ee84921-47dd-4033-b63a-18d7a039a3e4>2007-10-02 16:59:16 +0800
commit9da6ada6f8b8b3a3f66308a8e8f29783f6581a34 (patch)
tree57d18d30ab6dbeb23fe472d452bde949f016553c
parentf8d8c4da28de0478765fd29c166c0c3d025721fd (diff)
downloadgsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar.gz
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar.bz2
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar.lz
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar.xz
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.tar.zst
gsoc2013-empathy-9da6ada6f8b8b3a3f66308a8e8f29783f6581a34.zip
really fix protocol group
git-svn-id: svn+ssh://svn.gnome.org/svn/empathy/trunk@358 4ee84921-47dd-4033-b63a-18d7a039a3e4
-rw-r--r--libempathy/empathy-tp-contact-list.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/libempathy/empathy-tp-contact-list.c b/libempathy/empathy-tp-contact-list.c
index f5d565ed8..68bcf8cce 100644
--- a/libempathy/empathy-tp-contact-list.c
+++ b/libempathy/empathy-tp-contact-list.c
@@ -729,6 +729,7 @@ empathy_tp_contact_list_new (McAccount *account)
if (strcmp (protocol_name, "local-xmpp") == 0) {
priv->protocol_group = _("People nearby");
}
+g_print ("******%s\n", priv->protocol_group);
g_object_unref (profile);
/* Connect signals */
@@ -818,6 +819,10 @@ tp_contact_list_get_all_groups (EmpathyContactList *list)
g_return_val_if_fail (EMPATHY_IS_TP_CONTACT_LIST (list), NULL);
+ if (priv->protocol_group) {
+ groups = g_list_prepend (groups, g_strdup (priv->protocol_group));
+ }
+
for (l = priv->groups; l; l = l->next) {
const gchar *name;
@@ -825,10 +830,6 @@ tp_contact_list_get_all_groups (EmpathyContactList *list)
groups = g_list_prepend (groups, g_strdup (name));
}
- if (priv->protocol_group) {
- groups = g_list_prepend (groups, g_strdup (priv->protocol_group));
- }
-
return groups;
}
@@ -842,18 +843,19 @@ tp_contact_list_get_groups (EmpathyContactList *list,
g_return_val_if_fail (EMPATHY_IS_TP_CONTACT_LIST (list), NULL);
+ if (priv->protocol_group) {
+ ret = g_list_prepend (ret, g_strdup (priv->protocol_group));
+ }
+
groups = g_hash_table_lookup (priv->contacts_groups, contact);
if (!groups) {
- return NULL;
+ return ret;
}
for (l = *groups; l; l = l->next) {
ret = g_list_prepend (ret, g_strdup (l->data));
}
- if (priv->protocol_group) {
- ret = g_list_prepend (ret, g_strdup (priv->protocol_group));
- }
return ret;
}