[empathy] stop displaying favorite contacts on top of groups



commit a1aabfa9396be10ba988a84d3e7aac0ec6f10ffa
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date:   Tue Mar 9 17:01:47 2010 +0100

    stop displaying favorite contacts on top of groups
    
    They are already displayed in a separated group on top of the contact list

 libempathy-gtk/empathy-contact-list-store.c |   13 +++----------
 1 files changed, 3 insertions(+), 10 deletions(-)
---
diff --git a/libempathy-gtk/empathy-contact-list-store.c b/libempathy-gtk/empathy-contact-list-store.c
index 223d430..26ff11c 100644
--- a/libempathy-gtk/empathy-contact-list-store.c
+++ b/libempathy-gtk/empathy-contact-list-store.c
@@ -1554,8 +1554,6 @@ contact_list_store_get_group (EmpathyContactListStore *store,
 static gint
 compare_separator_and_groups (gboolean is_separator_a,
 			      gboolean is_separator_b,
-			      gboolean is_favourite_a,
-			      gboolean is_favourite_b,
 			      const gchar *name_a,
 			      const gchar *name_b,
 			      EmpathyContact *contact_a,
@@ -1570,13 +1568,8 @@ compare_separator_and_groups (gboolean is_separator_a,
 		}
 	}
 
-	/* Favorites are displayed first */
-	if (is_favourite_a && !is_favourite_b) {
-		return -1;
-	} else if (!is_favourite_a && is_favourite_b) {
-		return 1;
 	/* One group and one contact */
-	} else if (!contact_a && contact_b) {
+	if (!contact_a && contact_b) {
 		return 1;
 	} else if (contact_a && !contact_b) {
 		return -1;
@@ -1625,7 +1618,7 @@ contact_list_store_state_sort_func (GtkTreeModel *model,
 			    -1);
 
 	ret_val = compare_separator_and_groups (is_separator_a, is_separator_b,
-		is_favourite_a, is_favourite_b, name_a, name_b, contact_a, contact_b);
+		name_a, name_b, contact_a, contact_b);
 
 	if (ret_val != 0) {
 		goto free_and_out;
@@ -1684,7 +1677,7 @@ contact_list_store_name_sort_func (GtkTreeModel *model,
 			    -1);
 
 	ret_val = compare_separator_and_groups (is_separator_a, is_separator_b,
-		is_favourite_a, is_favourite_b, name_a, name_b, contact_a, contact_b);
+		name_a, name_b, contact_a, contact_b);
 
 	if (ret_val == 0)
 		ret_val = g_utf8_collate (name_a, name_b);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]