[vinagre/gnome-3-0] Disable Ctrl-Alt-Del action in view-only mode
- From: David King <davidk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vinagre/gnome-3-0] Disable Ctrl-Alt-Del action in view-only mode
- Date: Sat, 13 Aug 2011 12:09:15 +0000 (UTC)
commit 5c928350761440ad4c214c160db2554e48222209
Author: David King <amigadave amigadave com>
Date: Sat Aug 13 09:49:26 2011 +0200
Disable Ctrl-Alt-Del action in view-only mode
Fixes bug 656451.
plugins/vnc/vinagre-vnc-tab.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/plugins/vnc/vinagre-vnc-tab.c b/plugins/vnc/vinagre-vnc-tab.c
index 7a43701..795e7f2 100644
--- a/plugins/vnc/vinagre-vnc-tab.c
+++ b/plugins/vnc/vinagre-vnc-tab.c
@@ -40,7 +40,7 @@ struct _VinagreVncTabPrivate
gchar *clipboard_str;
GSList *connected_actions, *initialized_actions;
GtkWidget *viewonly_button, *scaling_button;
- GtkAction *scaling_action, *viewonly_action, *original_size_action, *keep_ratio_action;
+ GtkAction *scaling_action, *viewonly_action, *original_size_action, *keep_ratio_action, *ctrlaltdel_action;
gulong signal_clipboard, signal_align;
};
@@ -680,6 +680,7 @@ create_initialized_actions (VinagreVncTab *tab)
gtk_action_set_icon_name (a->action, "preferences-desktop-keyboard-shortcuts");
g_signal_connect (a->action, "activate", G_CALLBACK (send_ctrlaltdel_cb), tab);
list = g_slist_append (list, a);
+ tab->priv->ctrlaltdel_action = a->action;
return list;
}
@@ -943,6 +944,8 @@ vinagre_vnc_tab_set_viewonly (VinagreVncTab *tab, gboolean active) {
vnc_display_set_read_only (VNC_DISPLAY (tab->priv->vnc), active);
gtk_toggle_tool_button_set_active (GTK_TOGGLE_TOOL_BUTTON (tab->priv->viewonly_button),
active);
+
+ gtk_action_set_sensitive (tab->priv->ctrlaltdel_action, !active);
}
gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]