diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2012-02-08 21:42:36 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2012-02-08 22:13:34 +0800 |
commit | f0ca8ccc9e04507a25812e7d7e4a80500daf9569 (patch) | |
tree | 5d181416862b3f18d0f9d5097595aed6d01f35c1 /libempathy-gtk | |
parent | 1e10d537d22441f35ad57164e2231835a85698ed (diff) | |
download | gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar.gz gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar.bz2 gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar.lz gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar.xz gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.tar.zst gsoc2013-empathy-f0ca8ccc9e04507a25812e7d7e4a80500daf9569.zip |
Remove 'Link Contact' menu item
We want to use gnome-contacts and the 'Informations' menu item already starts
it.
https://bugzilla.gnome.org/show_bug.cgi?id=669482
Diffstat (limited to 'libempathy-gtk')
-rw-r--r-- | libempathy-gtk/empathy-individual-menu.c | 52 | ||||
-rw-r--r-- | libempathy-gtk/empathy-individual-menu.h | 9 |
2 files changed, 5 insertions, 56 deletions
diff --git a/libempathy-gtk/empathy-individual-menu.c b/libempathy-gtk/empathy-individual-menu.c index 4174cc759..cc1d88d47 100644 --- a/libempathy-gtk/empathy-individual-menu.c +++ b/libempathy-gtk/empathy-individual-menu.c @@ -91,8 +91,6 @@ static GtkWidget * empathy_individual_info_menu_item_new ( FolksIndividual *individual); static GtkWidget * empathy_individual_edit_menu_item_new ( FolksIndividual *individual); -static GtkWidget * empathy_individual_link_menu_item_new ( - FolksIndividual *individual); static GtkWidget * empathy_individual_invite_menu_item_new ( FolksIndividual *individual, EmpathyContact *contact); @@ -277,16 +275,6 @@ while_finish: } static void -individual_link_menu_item_activate_cb (EmpathyIndividualMenu *self) -{ - EmpathyIndividualMenuPriv *priv = GET_PRIV (self); - GtkWidget *dialog; - - dialog = empathy_linking_dialog_show (priv->individual, NULL); - g_signal_emit (self, signals[SIGNAL_LINK_CONTACTS_ACTIVATED], 0, dialog); -} - -static void empathy_individual_menu_init (EmpathyIndividualMenu *self) { EmpathyIndividualMenuPriv *priv = G_TYPE_INSTANCE_GET_PRIVATE (self, @@ -785,8 +773,7 @@ constructed (GObject *object) /* Separator */ if (features & (EMPATHY_INDIVIDUAL_FEATURE_EDIT | EMPATHY_INDIVIDUAL_FEATURE_INFO | - EMPATHY_INDIVIDUAL_FEATURE_FAVOURITE | - EMPATHY_INDIVIDUAL_FEATURE_LINK)) + EMPATHY_INDIVIDUAL_FEATURE_FAVOURITE)) { item = gtk_separator_menu_item_new (); gtk_menu_shell_append (shell, item); @@ -801,18 +788,6 @@ constructed (GObject *object) gtk_widget_show (item); } - /* Link */ - if (features & EMPATHY_INDIVIDUAL_FEATURE_LINK) - { - item = empathy_individual_link_menu_item_new (individual); - gtk_menu_shell_append (shell, item); - - g_signal_connect_swapped (item, "activate", - (GCallback) individual_link_menu_item_activate_cb, object); - - gtk_widget_show (item); - } - /* Log */ if (features & EMPATHY_INDIVIDUAL_FEATURE_LOG) { @@ -1477,31 +1452,6 @@ empathy_individual_edit_menu_item_new (FolksIndividual *individual) return item; } -static GtkWidget * -empathy_individual_link_menu_item_new (FolksIndividual *individual) -{ - GtkWidget *item; - /*GtkWidget *image;*/ - - g_return_val_if_fail (FOLKS_IS_INDIVIDUAL (individual), NULL); - - item = gtk_image_menu_item_new_with_mnemonic ( - /* Translators: this is a verb meaning "to connect two contacts together - * to form a meta-contact". */ - C_("Link individual (contextual menu)", "_Link Contacts…")); - /* TODO */ - /*image = gtk_image_new_from_icon_name (GTK_STOCK_EDIT, GTK_ICON_SIZE_MENU); - gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image); - gtk_widget_show (image);*/ - - /* Only allow trusted Individuals to be linked */ - gtk_widget_set_sensitive (item, - folks_individual_get_trust_level (individual) == - FOLKS_TRUST_LEVEL_PERSONAS); - - return item; -} - typedef struct { FolksIndividual *individual; diff --git a/libempathy-gtk/empathy-individual-menu.h b/libempathy-gtk/empathy-individual-menu.h index 71cedda34..a2187da6b 100644 --- a/libempathy-gtk/empathy-individual-menu.h +++ b/libempathy-gtk/empathy-individual-menu.h @@ -37,11 +37,10 @@ typedef enum { EMPATHY_INDIVIDUAL_FEATURE_EDIT = 1 << 3, EMPATHY_INDIVIDUAL_FEATURE_INFO = 1 << 4, EMPATHY_INDIVIDUAL_FEATURE_FAVOURITE = 1 << 5, - EMPATHY_INDIVIDUAL_FEATURE_LINK = 1 << 6, - EMPATHY_INDIVIDUAL_FEATURE_SMS = 1 << 7, - EMPATHY_INDIVIDUAL_FEATURE_CALL_PHONE = 1 << 8, - EMPATHY_INDIVIDUAL_FEATURE_ADD_CONTACT = 1 << 9, - EMPATHY_INDIVIDUAL_FEATURE_BLOCK = 1 << 10, + EMPATHY_INDIVIDUAL_FEATURE_SMS = 1 << 6, + EMPATHY_INDIVIDUAL_FEATURE_CALL_PHONE = 1 << 7, + EMPATHY_INDIVIDUAL_FEATURE_ADD_CONTACT = 1 << 8, + EMPATHY_INDIVIDUAL_FEATURE_BLOCK = 1 << 9, } EmpathyIndividualFeatureFlags; #define EMPATHY_TYPE_INDIVIDUAL_MENU (empathy_individual_menu_get_type ()) |