aboutsummaryrefslogtreecommitdiffstats
path: root/modules/calendar/e-cal-shell-view-actions.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2011-03-28 03:16:39 +0800
committerMatthew Barnes <mbarnes@redhat.com>2011-03-28 06:38:39 +0800
commitba6a2343869f6be82f44261f183cd6925659d5ee (patch)
treef7356964d4780d8889c439f9c8271c7d71315ab3 /modules/calendar/e-cal-shell-view-actions.c
parentf35931919049a645681207856c384d70a749020c (diff)
downloadgsoc2013-evolution-ba6a2343869f6be82f44261f183cd6925659d5ee.tar.gz
gsoc2013-evolution-ba6a2343869f6be82f44261f183cd6925659d5ee.tar.zst
gsoc2013-evolution-ba6a2343869f6be82f44261f183cd6925659d5ee.zip
Restore lockdown integration.
With lockdown settings available through GSettings, widgets can handle lockdown integration themselves without having to use EShellSettings. Also fixed a few places where printing or save-to-disk actions were either not properly wired up or not responding to lockdown settings, but much more work needs done. Attachments, for example, are not honoring the disable-save-to-disk setting at all. This too requires the recently-added gsettings-desktop-schemas dependency.
Diffstat (limited to 'modules/calendar/e-cal-shell-view-actions.c')
-rw-r--r--modules/calendar/e-cal-shell-view-actions.c37
1 files changed, 26 insertions, 11 deletions
diff --git a/modules/calendar/e-cal-shell-view-actions.c b/modules/calendar/e-cal-shell-view-actions.c
index 5e16b6db5b..ba72a41748 100644
--- a/modules/calendar/e-cal-shell-view-actions.c
+++ b/modules/calendar/e-cal-shell-view-actions.c
@@ -1467,13 +1467,6 @@ static GtkActionEntry calendar_entries[] = {
NULL, /* XXX Add a tooltip! */
G_CALLBACK (action_event_reply_all_cb) },
- { "event-save-as",
- GTK_STOCK_SAVE_AS,
- N_("Save as iCalendar..."),
- NULL,
- NULL, /* XXX Add a tooltip! */
- G_CALLBACK (action_event_save_as_cb) },
-
{ "event-schedule",
NULL,
N_("_Schedule Meeting..."),
@@ -1587,10 +1580,6 @@ static EPopupActionEntry calendar_popup_entries[] = {
NULL,
"event-reply-all" },
- { "event-popup-save-as",
- NULL,
- "event-save-as" },
-
{ "event-popup-schedule",
NULL,
"event-schedule" },
@@ -1741,6 +1730,23 @@ static EPopupActionEntry lockdown_printing_popup_entries[] = {
"event-print" }
};
+static GtkActionEntry lockdown_save_to_disk_entries[] = {
+
+ { "event-save-as",
+ GTK_STOCK_SAVE_AS,
+ N_("Save as iCalendar..."),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_event_save_as_cb) },
+};
+
+static EPopupActionEntry lockdown_save_to_disk_popup_entries[] = {
+
+ { "event-popup-save-as",
+ NULL,
+ "event-save-as" },
+};
+
void
e_cal_shell_view_actions_init (ECalShellView *cal_shell_view)
{
@@ -1790,6 +1796,15 @@ e_cal_shell_view_actions_init (ECalShellView *cal_shell_view)
action_group, lockdown_printing_popup_entries,
G_N_ELEMENTS (lockdown_printing_popup_entries));
+ /* Lockdown Save-to-Disk Actions */
+ action_group = ACTION_GROUP (LOCKDOWN_SAVE_TO_DISK);
+ gtk_action_group_add_actions (
+ action_group, lockdown_save_to_disk_entries,
+ G_N_ELEMENTS (lockdown_save_to_disk_entries), cal_shell_view);
+ e_action_group_add_popup_actions (
+ action_group, lockdown_save_to_disk_popup_entries,
+ G_N_ELEMENTS (lockdown_save_to_disk_popup_entries));
+
/* Fine tuning. */
action = ACTION (CALENDAR_GO_TODAY);