[empathy] Desensitise the "Link…" menu entry for untrusted Individuals
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy] Desensitise the "Link…" menu entry for untrusted Individuals
- Date: Fri, 27 Aug 2010 10:56:10 +0000 (UTC)
commit a0d79de6f5151ee14b25364060e5dd2338f800a9
Author: Philip Withnall <philip withnall collabora co uk>
Date: Wed Aug 25 19:04:09 2010 +0100
Desensitise the "Linkâ?¦" menu entry for untrusted Individuals
This prevents the linking dialogue from being opened for local-xmpp contacts,
who cannot be trusted.
This bumps Empathy's dependency on libfolks to 0.1.15. Helps: bgo#627930
configure.ac | 2 +-
libempathy-gtk/empathy-individual-menu.c | 5 +++++
2 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index a80a511..525272e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -31,7 +31,7 @@ AC_COPYRIGHT([
# Minimal version required
# Hardp deps
-FOLKS_REQUIRED=0.1.13
+FOLKS_REQUIRED=0.1.15
GCONF_REQUIRED=1.2.0
GLIB_REQUIRED=2.25.9
GNUTLS_REQUIRED=2.8.5
diff --git a/libempathy-gtk/empathy-individual-menu.c b/libempathy-gtk/empathy-individual-menu.c
index 99dea73..549e026 100644
--- a/libempathy-gtk/empathy-individual-menu.c
+++ b/libempathy-gtk/empathy-individual-menu.c
@@ -832,6 +832,11 @@ empathy_individual_link_menu_item_new (FolksIndividual *individual)
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);
+
g_signal_connect_swapped (item, "activate",
G_CALLBACK (individual_link_menu_item_activate_cb), individual);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]