aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-03-09 18:22:32 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-03-15 16:28:41 +0800
commit40586f1a404d9e053ce4f282c50f3988e6976659 (patch)
tree238f15819481ed12ae2e45a10d40e23865193bc7
parent8df2cf237283de1b049b4c24b0906384e45c4320 (diff)
downloadgsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar.gz
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar.bz2
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar.lz
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar.xz
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.tar.zst
gsoc2013-empathy-40586f1a404d9e053ce4f282c50f3988e6976659.zip
remove 'favorite' column in the contact list
We can use the contact menu now.
-rw-r--r--libempathy-gtk/empathy-contact-list-view.c88
1 files changed, 0 insertions, 88 deletions
diff --git a/libempathy-gtk/empathy-contact-list-view.c b/libempathy-gtk/empathy-contact-list-view.c
index 8fb08dfdc..705494e4a 100644
--- a/libempathy-gtk/empathy-contact-list-view.c
+++ b/libempathy-gtk/empathy-contact-list-view.c
@@ -34,7 +34,6 @@
#include <telepathy-glib/account-manager.h>
#include <telepathy-glib/util.h>
-#include <extensions/extensions.h>
#include <libempathy/empathy-call-factory.h>
#include <libempathy/empathy-tp-contact-factory.h>
#include <libempathy/empathy-contact-list.h>
@@ -817,40 +816,6 @@ contact_list_view_call_activated_cb (
g_object_unref (contact);
}
-#if HAVE_FAVOURITE_CONTACTS
-static void
-contact_list_view_favourite_toggled_cb (
- EmpathyCellRendererActivatable *cell,
- const gchar *path_string,
- EmpathyContactListView *view)
-{
- EmpathyContactListViewPriv *priv = GET_PRIV (view);
- GtkTreeModel *model;
- GtkTreeIter iter;
- EmpathyContact *contact;
- EmpathyContactList *list;
-
- model = gtk_tree_view_get_model (GTK_TREE_VIEW (view));
- if (!gtk_tree_model_get_iter_from_string (model, &iter, path_string))
- return;
-
- gtk_tree_model_get (model, &iter,
- EMPATHY_CONTACT_LIST_STORE_COL_CONTACT, &contact,
- -1);
- if (contact == NULL)
- return;
-
- list = empathy_contact_list_store_get_list_iface (priv->store);
- if (empathy_contact_list_is_favourite (list, contact)) {
- empathy_contact_list_remove_from_favourites (list, contact);
- } else {
- empathy_contact_list_add_to_favourites (list, contact);
- }
-
- g_object_unref (contact);
-}
-#endif /* HAVE_FAVOURITE_CONTACTS */
-
static void
contact_list_view_cell_set_background (EmpathyContactListView *view,
GtkCellRenderer *cell,
@@ -1033,41 +998,6 @@ contact_list_view_expander_cell_data_func (GtkTreeViewColumn *column,
contact_list_view_cell_set_background (view, cell, is_group, is_active);
}
-#if HAVE_FAVOURITE_CONTACTS
-static void
-contact_list_view_favourite_cell_data_func (
- GtkTreeViewColumn *tree_column,
- GtkCellRenderer *cell,
- GtkTreeModel *model,
- GtkTreeIter *iter,
- EmpathyContactListView *view)
-{
- gboolean is_group;
- gboolean is_active;
- gboolean is_separator;
- gboolean is_favourite;
- const gchar *icon_name = NULL;
-
- gtk_tree_model_get (model, iter,
- EMPATHY_CONTACT_LIST_STORE_COL_IS_GROUP, &is_group,
- EMPATHY_CONTACT_LIST_STORE_COL_IS_ACTIVE, &is_active,
- EMPATHY_CONTACT_LIST_STORE_COL_IS_SEPARATOR, &is_separator,
- EMPATHY_CONTACT_LIST_STORE_COL_IS_FAVOURITE, &is_favourite,
- -1);
-
- if (!is_separator && !is_group)
- icon_name = (is_favourite? EMPATHY_IMAGE_FAVOURITE :
- EMPATHY_IMAGE_UNFAVOURITE);
-
- g_object_set (cell,
- "visible", (icon_name != NULL),
- "icon-name", icon_name,
- NULL);
-
- contact_list_view_cell_set_background (view, cell, is_group, is_active);
-}
-#endif /* HAVE_FAVOURITE_CONTACTS */
-
static void
contact_list_view_row_expand_or_collapse_cb (EmpathyContactListView *view,
GtkTreeIter *iter,
@@ -1171,24 +1101,6 @@ contact_list_view_setup (EmpathyContactListView *view)
col = gtk_tree_view_column_new ();
-#if HAVE_FAVOURITE_CONTACTS
- /* Favourite Icon */
- cell = empathy_cell_renderer_activatable_new ();
- gtk_tree_view_column_pack_start (col, cell, FALSE);
- gtk_tree_view_column_set_cell_data_func (
- col, cell,
- (GtkTreeCellDataFunc) contact_list_view_favourite_cell_data_func,
- view, NULL);
-
- g_object_set (cell,
- "visible", FALSE,
- NULL);
-
- g_signal_connect (cell, "path-activated",
- G_CALLBACK (contact_list_view_favourite_toggled_cb),
- view);
-#endif
-
/* State */
cell = gtk_cell_renderer_pixbuf_new ();
gtk_tree_view_column_pack_start (col, cell, FALSE);