aboutsummaryrefslogtreecommitdiffstats
path: root/modules/calendar/e-cal-shell-sidebar.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2012-07-26 19:54:33 +0800
committerMatthew Barnes <mbarnes@redhat.com>2012-08-03 23:40:13 +0800
commit4fedf14c7b90d1bab1906d0e1ffd676af620c15c (patch)
treeb0df6fd65232a528924eb7e0a3b0fda5119390f8 /modules/calendar/e-cal-shell-sidebar.c
parentcdc45d0ef235591a93e980f7513e5fadd7abb315 (diff)
downloadgsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar.gz
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar.bz2
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar.lz
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar.xz
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.tar.zst
gsoc2013-evolution-4fedf14c7b90d1bab1906d0e1ffd676af620c15c.zip
Enable "delete" action for remote-deletable sources.
Diffstat (limited to 'modules/calendar/e-cal-shell-sidebar.c')
-rw-r--r--modules/calendar/e-cal-shell-sidebar.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/calendar/e-cal-shell-sidebar.c b/modules/calendar/e-cal-shell-sidebar.c
index fa58514806..1f4ab0219c 100644
--- a/modules/calendar/e-cal-shell-sidebar.c
+++ b/modules/calendar/e-cal-shell-sidebar.c
@@ -753,6 +753,8 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
ESource *source;
gboolean is_writable = FALSE;
gboolean is_removable = FALSE;
+ gboolean is_remote_creatable = FALSE;
+ gboolean is_remote_deletable = FALSE;
gboolean in_collection = FALSE;
gboolean refresh_supported = FALSE;
gboolean has_primary_source = FALSE;
@@ -771,6 +773,8 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
has_primary_source = TRUE;
is_writable = e_source_get_writable (source);
is_removable = e_source_get_removable (source);
+ is_remote_creatable = e_source_get_remote_creatable (source);
+ is_remote_deletable = e_source_get_remote_deletable (source);
collection = e_source_registry_find_extension (
registry, source, E_SOURCE_EXTENSION_COLLECTION);
@@ -795,6 +799,10 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_WRITABLE;
if (is_removable)
state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_REMOVABLE;
+ if (is_remote_creatable)
+ state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_REMOTE_CREATABLE;
+ if (is_remote_deletable)
+ state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_REMOTE_DELETABLE;
if (in_collection)
state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IN_COLLECTION;
if (refresh_supported)