aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-10-25 20:33:47 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-10-25 20:33:47 +0800
commit8f0fbd89ee0d514bdc664850541416cac9090204 (patch)
tree5327e4f876d1be1c1ce91cdbb3131160d3998b3c
parent1e6d192d7a61c14fefae302f2109a91a9a916287 (diff)
parent34a97e543d2d8e306333d3e8682316c7e0ea8444 (diff)
downloadgsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar.gz
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar.bz2
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar.lz
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar.xz
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.tar.zst
gsoc2013-empathy-8f0fbd89ee0d514bdc664850541416cac9090204.zip
Merge remote branch 'vminko/fix-573283'
-rw-r--r--libempathy-gtk/empathy-contact-menu.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/libempathy-gtk/empathy-contact-menu.c b/libempathy-gtk/empathy-contact-menu.c
index 921e8d783..c7fd19b09 100644
--- a/libempathy-gtk/empathy-contact-menu.c
+++ b/libempathy-gtk/empathy-contact-menu.c
@@ -231,6 +231,7 @@ empathy_contact_chat_menu_item_new (EmpathyContact *contact)
image = gtk_image_new_from_icon_name (EMPATHY_IMAGE_MESSAGE,
GTK_ICON_SIZE_MENU);
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
+ gtk_widget_set_sensitive (item, !empathy_contact_is_user (contact));
gtk_widget_show (image);
g_signal_connect (item, "activate",
@@ -261,7 +262,8 @@ empathy_contact_audio_call_menu_item_new (EmpathyContact *contact)
image = gtk_image_new_from_icon_name (EMPATHY_IMAGE_VOIP,
GTK_ICON_SIZE_MENU);
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
- gtk_widget_set_sensitive (item, empathy_contact_can_voip_audio (contact));
+ gtk_widget_set_sensitive (item, empathy_contact_can_voip_audio (contact) &&
+ !empathy_contact_is_user (contact));
gtk_widget_show (image);
g_signal_connect (item, "activate",
@@ -291,7 +293,8 @@ empathy_contact_video_call_menu_item_new (EmpathyContact *contact)
image = gtk_image_new_from_icon_name (EMPATHY_IMAGE_VIDEO_CALL,
GTK_ICON_SIZE_MENU);
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
- gtk_widget_set_sensitive (item, empathy_contact_can_voip_video (contact));
+ gtk_widget_set_sensitive (item, empathy_contact_can_voip_video (contact) &&
+ !empathy_contact_is_user (contact));
gtk_widget_show (image);
g_signal_connect (item, "activate",
@@ -352,7 +355,8 @@ empathy_contact_file_transfer_menu_item_new (EmpathyContact *contact)
item = gtk_image_menu_item_new_with_mnemonic (_("Send File"));
image = gtk_image_new_from_icon_name (EMPATHY_IMAGE_DOCUMENT_SEND,
GTK_ICON_SIZE_MENU);
- gtk_widget_set_sensitive (item, empathy_contact_can_send_files (contact));
+ gtk_widget_set_sensitive (item, empathy_contact_can_send_files (contact) &&
+ !empathy_contact_is_user (contact));
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
gtk_widget_show (image);
@@ -576,6 +580,12 @@ empathy_contact_invite_menu_item_new (EmpathyContact *contact)
GTK_ICON_SIZE_MENU);
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
+ if (empathy_contact_is_user (contact)) {
+ gtk_widget_set_sensitive (item, FALSE);
+ gtk_widget_show (image);
+ return item;
+ }
+
mgr = empathy_chatroom_manager_dup_singleton (NULL);
rooms = empathy_chatroom_manager_get_chatrooms (mgr,
empathy_contact_get_account (contact));