[evolution] Bug 494394 - No way for the user to refresh a calendar
- From: Chenthill Palanisamy <pchen src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [evolution] Bug 494394 - No way for the user to refresh a calendar
- Date: Mon, 30 Nov 2009 07:05:32 +0000 (UTC)
commit 0b1658ed7a215dad8295b02a30d5220011e199f1
Author: Milan Crha <mcrha redhat com>
Date: Mon Nov 30 12:31:31 2009 +0530
Bug 494394 - No way for the user to refresh a calendar
modules/calendar/e-cal-shell-sidebar.c | 7 ++++
modules/calendar/e-cal-shell-sidebar.h | 3 +-
modules/calendar/e-cal-shell-view-actions.c | 40 ++++++++++++++++++++++++++
modules/calendar/e-cal-shell-view-actions.h | 2 +
modules/calendar/e-cal-shell-view.c | 7 ++++
modules/calendar/e-memo-shell-sidebar.c | 7 ++++
modules/calendar/e-memo-shell-sidebar.h | 3 +-
modules/calendar/e-memo-shell-view-actions.c | 40 ++++++++++++++++++++++++++
modules/calendar/e-memo-shell-view-actions.h | 2 +
modules/calendar/e-memo-shell-view.c | 7 ++++
modules/calendar/e-task-shell-sidebar.c | 7 ++++
modules/calendar/e-task-shell-sidebar.h | 3 +-
modules/calendar/e-task-shell-view-actions.c | 40 ++++++++++++++++++++++++++
modules/calendar/e-task-shell-view-actions.h | 2 +
modules/calendar/e-task-shell-view.c | 7 ++++
ui/evolution-calendars.ui | 1 +
ui/evolution-memos.ui | 1 +
ui/evolution-tasks.ui | 1 +
18 files changed, 177 insertions(+), 3 deletions(-)
---
diff --git a/modules/calendar/e-cal-shell-sidebar.c b/modules/calendar/e-cal-shell-sidebar.c
index 244136e..5732990 100644
--- a/modules/calendar/e-cal-shell-sidebar.c
+++ b/modules/calendar/e-cal-shell-sidebar.c
@@ -510,6 +510,7 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
ESource *source;
gboolean can_delete = FALSE;
gboolean is_system = FALSE;
+ gboolean refresh_supported = FALSE;
guint32 state = 0;
cal_shell_sidebar = E_CAL_SHELL_SIDEBAR (shell_sidebar);
@@ -517,6 +518,7 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
source = e_source_selector_peek_primary_selection (selector);
if (source != NULL) {
+ ECal *client;
const gchar *uri;
const gchar *delete;
@@ -526,6 +528,9 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
can_delete = !is_system;
delete = e_source_get_property (source, "delete");
can_delete &= (delete == NULL || strcmp (delete, "no") != 0);
+
+ client = g_hash_table_lookup (cal_shell_sidebar->priv->client_table, e_source_peek_uid (source));
+ refresh_supported = client && e_cal_get_refresh_supported (client);
}
if (source != NULL)
@@ -534,6 +539,8 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
state |= E_CAL_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE;
if (is_system)
state |= E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM;
+ if (refresh_supported)
+ state |= E_CAL_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH;
return state;
}
diff --git a/modules/calendar/e-cal-shell-sidebar.h b/modules/calendar/e-cal-shell-sidebar.h
index 47dc9fa..6169d30 100644
--- a/modules/calendar/e-cal-shell-sidebar.h
+++ b/modules/calendar/e-cal-shell-sidebar.h
@@ -57,7 +57,8 @@ typedef struct _ECalShellSidebarPrivate ECalShellSidebarPrivate;
enum {
E_CAL_SHELL_SIDEBAR_HAS_PRIMARY_SOURCE = 1 << 0,
E_CAL_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE = 1 << 1,
- E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2
+ E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2,
+ E_CAL_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH = 1 << 3
};
struct _ECalShellSidebar {
diff --git a/modules/calendar/e-cal-shell-view-actions.c b/modules/calendar/e-cal-shell-view-actions.c
index 68da6b2..a8c8fc1 100644
--- a/modules/calendar/e-cal-shell-view-actions.c
+++ b/modules/calendar/e-cal-shell-view-actions.c
@@ -350,6 +350,35 @@ exit:
}
static void
+action_calendar_refresh_cb (GtkAction *action,
+ ECalShellView *cal_shell_view)
+{
+ ECal *client;
+ ECalModel *model;
+ ESource *source;
+ gchar *uri;
+ GError *error = NULL;
+
+ model = e_cal_shell_content_get_model (cal_shell_view->priv->cal_shell_content);
+ source = e_source_selector_peek_primary_selection (e_cal_shell_sidebar_get_selector (cal_shell_view->priv->cal_shell_sidebar));
+ g_return_if_fail (E_IS_SOURCE (source));
+
+ uri = e_source_get_uri (source);
+ client = e_cal_model_get_client_for_uri (model, uri);
+ g_free (uri);
+
+ if (client == NULL)
+ return;
+
+ g_return_if_fail (e_cal_get_refresh_supported (client));
+
+ if (!e_cal_refresh (client, &error) && error) {
+ g_warning ("%s: Failed to refresh '%s', %s\n", G_STRFUNC, e_source_peek_name (source), error->message);
+ g_error_free (error);
+ }
+}
+
+static void
action_calendar_rename_cb (GtkAction *action,
ECalShellView *cal_shell_view)
{
@@ -1264,6 +1293,13 @@ static GtkActionEntry calendar_entries[] = {
N_("Purge old appointments and meetings"),
G_CALLBACK (action_calendar_purge_cb) },
+ { "calendar-refresh",
+ GTK_STOCK_REFRESH,
+ N_("Re_fresh"),
+ NULL,
+ N_("Refresh the selected calendar"),
+ G_CALLBACK (action_calendar_refresh_cb) },
+
{ "calendar-rename",
NULL,
N_("_Rename..."),
@@ -1454,6 +1490,10 @@ static EPopupActionEntry calendar_popup_entries[] = {
NULL,
"calendar-properties" },
+ { "calendar-popup-refresh",
+ NULL,
+ "calendar-refresh" },
+
{ "calendar-popup-rename",
NULL,
"calendar-rename" },
diff --git a/modules/calendar/e-cal-shell-view-actions.h b/modules/calendar/e-cal-shell-view-actions.h
index 94ad66c..a6b1c3d 100644
--- a/modules/calendar/e-cal-shell-view-actions.h
+++ b/modules/calendar/e-cal-shell-view-actions.h
@@ -47,6 +47,8 @@
E_SHELL_WINDOW_ACTION ((window), "calendar-properties")
#define E_SHELL_WINDOW_ACTION_CALENDAR_PURGE(window) \
E_SHELL_WINDOW_ACTION ((window), "calendar-purge")
+#define E_SHELL_WINDOW_ACTION_CALENDAR_REFRESH(window) \
+ E_SHELL_WINDOW_ACTION ((window), "calendar-refresh")
#define E_SHELL_WINDOW_ACTION_CALENDAR_RENAME(window) \
E_SHELL_WINDOW_ACTION ((window), "calendar-rename")
#define E_SHELL_WINDOW_ACTION_CALENDAR_SELECT_ONE(window) \
diff --git a/modules/calendar/e-cal-shell-view.c b/modules/calendar/e-cal-shell-view.c
index 396cdec..47d7349 100644
--- a/modules/calendar/e-cal-shell-view.c
+++ b/modules/calendar/e-cal-shell-view.c
@@ -291,6 +291,7 @@ cal_shell_view_update_actions (EShellView *shell_view)
gboolean is_meeting = FALSE;
gboolean is_delegatable = FALSE;
gboolean clipboard_has_calendar;
+ gboolean refresh_supported = FALSE;
priv = E_CAL_SHELL_VIEW_GET_PRIVATE (shell_view);
@@ -367,6 +368,8 @@ cal_shell_view_update_actions (EShellView *shell_view)
(state & E_CAL_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE);
primary_source_is_system =
(state & E_CAL_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM);
+ refresh_supported =
+ (state & E_CAL_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH);
action = ACTION (CALENDAR_COPY);
sensitive = has_primary_source;
@@ -380,6 +383,10 @@ cal_shell_view_update_actions (EShellView *shell_view)
sensitive = has_primary_source;
gtk_action_set_sensitive (action, sensitive);
+ action = ACTION (CALENDAR_REFRESH);
+ sensitive = refresh_supported;
+ gtk_action_set_sensitive (action, sensitive);
+
action = ACTION (CALENDAR_RENAME);
sensitive = can_delete_primary_source;
gtk_action_set_sensitive (action, sensitive);
diff --git a/modules/calendar/e-memo-shell-sidebar.c b/modules/calendar/e-memo-shell-sidebar.c
index 6da8998..dee57e0 100644
--- a/modules/calendar/e-memo-shell-sidebar.c
+++ b/modules/calendar/e-memo-shell-sidebar.c
@@ -455,6 +455,7 @@ memo_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
ESource *source;
gboolean can_delete = FALSE;
gboolean is_system = FALSE;
+ gboolean refresh_supported = FALSE;
guint32 state = 0;
memo_shell_sidebar = E_MEMO_SHELL_SIDEBAR (shell_sidebar);
@@ -462,6 +463,7 @@ memo_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
source = e_source_selector_peek_primary_selection (selector);
if (source != NULL) {
+ ECal *client;
const gchar *uri;
const gchar *delete;
@@ -471,6 +473,9 @@ memo_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
can_delete = !is_system;
delete = e_source_get_property (source, "delete");
can_delete &= (delete == NULL || strcmp (delete, "no") != 0);
+
+ client = g_hash_table_lookup (memo_shell_sidebar->priv->client_table, e_source_peek_uid (source));
+ refresh_supported = client && e_cal_get_refresh_supported (client);
}
if (source != NULL)
@@ -479,6 +484,8 @@ memo_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
state |= E_MEMO_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE;
if (is_system)
state |= E_MEMO_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM;
+ if (refresh_supported)
+ state |= E_MEMO_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH;
return state;
}
diff --git a/modules/calendar/e-memo-shell-sidebar.h b/modules/calendar/e-memo-shell-sidebar.h
index 5df8089..8eabee1 100644
--- a/modules/calendar/e-memo-shell-sidebar.h
+++ b/modules/calendar/e-memo-shell-sidebar.h
@@ -56,7 +56,8 @@ typedef struct _EMemoShellSidebarPrivate EMemoShellSidebarPrivate;
enum {
E_MEMO_SHELL_SIDEBAR_HAS_PRIMARY_SOURCE = 1 << 0,
E_MEMO_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE = 1 << 1,
- E_MEMO_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2
+ E_MEMO_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2,
+ E_MEMO_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH = 1 << 3
};
struct _EMemoShellSidebar {
diff --git a/modules/calendar/e-memo-shell-view-actions.c b/modules/calendar/e-memo-shell-view-actions.c
index 734a7c5..c36b456 100644
--- a/modules/calendar/e-memo-shell-view-actions.c
+++ b/modules/calendar/e-memo-shell-view-actions.c
@@ -292,6 +292,35 @@ action_memo_list_properties_cb (GtkAction *action,
}
static void
+action_memo_list_refresh_cb (GtkAction *action,
+ EMemoShellView *memo_shell_view)
+{
+ ECal *client;
+ ECalModel *model;
+ ESource *source;
+ gchar *uri;
+ GError *error = NULL;
+
+ model = e_memo_shell_content_get_memo_model (memo_shell_view->priv->memo_shell_content);
+ source = e_source_selector_peek_primary_selection (e_memo_shell_sidebar_get_selector (memo_shell_view->priv->memo_shell_sidebar));
+ g_return_if_fail (E_IS_SOURCE (source));
+
+ uri = e_source_get_uri (source);
+ client = e_cal_model_get_client_for_uri (model, uri);
+ g_free (uri);
+
+ if (client == NULL)
+ return;
+
+ g_return_if_fail (e_cal_get_refresh_supported (client));
+
+ if (!e_cal_refresh (client, &error) && error) {
+ g_warning ("%s: Failed to refresh '%s', %s\n", G_STRFUNC, e_source_peek_name (source), error->message);
+ g_error_free (error);
+ }
+}
+
+static void
action_memo_list_rename_cb (GtkAction *action,
EMemoShellView *memo_shell_view)
{
@@ -624,6 +653,13 @@ static GtkActionEntry memo_entries[] = {
NULL, /* XXX Add a tooltip! */
G_CALLBACK (action_memo_list_properties_cb) },
+ { "memo-list-refresh",
+ GTK_STOCK_REFRESH,
+ N_("Re_fresh"),
+ NULL,
+ N_("Refresh the selected memo list"),
+ G_CALLBACK (action_memo_list_refresh_cb) },
+
{ "memo-list-rename",
NULL,
N_("_Rename..."),
@@ -683,6 +719,10 @@ static EPopupActionEntry memo_popup_entries[] = {
NULL,
"memo-list-properties" },
+ { "memo-list-popup-refresh",
+ NULL,
+ "memo-list-refresh" },
+
{ "memo-list-popup-rename",
NULL,
"memo-list-rename" },
diff --git a/modules/calendar/e-memo-shell-view-actions.h b/modules/calendar/e-memo-shell-view-actions.h
index 9fe4d69..cb4309c 100644
--- a/modules/calendar/e-memo-shell-view-actions.h
+++ b/modules/calendar/e-memo-shell-view-actions.h
@@ -65,6 +65,8 @@
E_SHELL_WINDOW_ACTION ((window), "memo-list-print-preview")
#define E_SHELL_WINDOW_ACTION_MEMO_LIST_PROPERTIES(window) \
E_SHELL_WINDOW_ACTION ((window), "memo-list-properties")
+#define E_SHELL_WINDOW_ACTION_MEMO_LIST_REFRESH(window) \
+ E_SHELL_WINDOW_ACTION ((window), "memo-list-refresh")
#define E_SHELL_WINDOW_ACTION_MEMO_LIST_RENAME(window) \
E_SHELL_WINDOW_ACTION ((window), "memo-list-rename")
#define E_SHELL_WINDOW_ACTION_MEMO_LIST_SELECT_ONE(window) \
diff --git a/modules/calendar/e-memo-shell-view.c b/modules/calendar/e-memo-shell-view.c
index 242bdfc..206e50c 100644
--- a/modules/calendar/e-memo-shell-view.c
+++ b/modules/calendar/e-memo-shell-view.c
@@ -176,6 +176,7 @@ memo_shell_view_update_actions (EShellView *shell_view)
gboolean selection_has_url;
gboolean single_memo_selected;
gboolean sources_are_editable;
+ gboolean refresh_supported;
priv = E_MEMO_SHELL_VIEW_GET_PRIVATE (shell_view);
@@ -204,6 +205,8 @@ memo_shell_view_update_actions (EShellView *shell_view)
(state & E_MEMO_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE);
primary_source_is_system =
(state & E_MEMO_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM);
+ refresh_supported =
+ (state & E_MEMO_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH);
any_memos_selected =
(single_memo_selected || multiple_memos_selected);
@@ -245,6 +248,10 @@ memo_shell_view_update_actions (EShellView *shell_view)
sensitive = has_primary_source;
gtk_action_set_sensitive (action, sensitive);
+ action = ACTION (MEMO_LIST_REFRESH);
+ sensitive = refresh_supported;
+ gtk_action_set_sensitive (action, sensitive);
+
action = ACTION (MEMO_LIST_RENAME);
sensitive = can_delete_primary_source;
gtk_action_set_sensitive (action, sensitive);
diff --git a/modules/calendar/e-task-shell-sidebar.c b/modules/calendar/e-task-shell-sidebar.c
index 9107d65..df3761f 100644
--- a/modules/calendar/e-task-shell-sidebar.c
+++ b/modules/calendar/e-task-shell-sidebar.c
@@ -453,6 +453,7 @@ task_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
ESource *source;
gboolean can_delete = FALSE;
gboolean is_system = FALSE;
+ gboolean refresh_supported = FALSE;
guint32 state = 0;
task_shell_sidebar = E_TASK_SHELL_SIDEBAR (shell_sidebar);
@@ -460,6 +461,7 @@ task_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
source = e_source_selector_peek_primary_selection (selector);
if (source != NULL) {
+ ECal *client;
const gchar *uri;
const gchar *delete;
@@ -469,6 +471,9 @@ task_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
can_delete = !is_system;
delete = e_source_get_property (source, "delete");
can_delete &= (delete == NULL || strcmp (delete, "no") != 0);
+
+ client = g_hash_table_lookup (task_shell_sidebar->priv->client_table, e_source_peek_uid (source));
+ refresh_supported = client && e_cal_get_refresh_supported (client);
}
if (source != NULL)
@@ -477,6 +482,8 @@ task_shell_sidebar_check_state (EShellSidebar *shell_sidebar)
state |= E_TASK_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE;
if (is_system)
state |= E_TASK_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM;
+ if (refresh_supported)
+ state |= E_TASK_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH;
return state;
}
diff --git a/modules/calendar/e-task-shell-sidebar.h b/modules/calendar/e-task-shell-sidebar.h
index 81021b8..6a18279 100644
--- a/modules/calendar/e-task-shell-sidebar.h
+++ b/modules/calendar/e-task-shell-sidebar.h
@@ -56,7 +56,8 @@ typedef struct _ETaskShellSidebarPrivate ETaskShellSidebarPrivate;
enum {
E_TASK_SHELL_SIDEBAR_HAS_PRIMARY_SOURCE = 1 << 0,
E_TASK_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE = 1 << 1,
- E_TASK_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2
+ E_TASK_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM = 1 << 2,
+ E_TASK_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH = 1 << 3
};
struct _ETaskShellSidebar {
diff --git a/modules/calendar/e-task-shell-view-actions.c b/modules/calendar/e-task-shell-view-actions.c
index 0617778..872cd78 100644
--- a/modules/calendar/e-task-shell-view-actions.c
+++ b/modules/calendar/e-task-shell-view-actions.c
@@ -323,6 +323,35 @@ action_task_list_properties_cb (GtkAction *action,
}
static void
+action_task_list_refresh_cb (GtkAction *action,
+ ETaskShellView *task_shell_view)
+{
+ ECal *client;
+ ECalModel *model;
+ ESource *source;
+ gchar *uri;
+ GError *error = NULL;
+
+ model = e_task_shell_content_get_task_model (task_shell_view->priv->task_shell_content);
+ source = e_source_selector_peek_primary_selection (e_task_shell_sidebar_get_selector (task_shell_view->priv->task_shell_sidebar));
+ g_return_if_fail (E_IS_SOURCE (source));
+
+ uri = e_source_get_uri (source);
+ client = e_cal_model_get_client_for_uri (model, uri);
+ g_free (uri);
+
+ if (client == NULL)
+ return;
+
+ g_return_if_fail (e_cal_get_refresh_supported (client));
+
+ if (!e_cal_refresh (client, &error) && error) {
+ g_warning ("%s: Failed to refresh '%s', %s\n", G_STRFUNC, e_source_peek_name (source), error->message);
+ g_error_free (error);
+ }
+}
+
+static void
action_task_list_rename_cb (GtkAction *action,
ETaskShellView *task_shell_view)
{
@@ -748,6 +777,13 @@ static GtkActionEntry task_entries[] = {
NULL, /* XXX Add a tooltip! */
G_CALLBACK (action_task_list_properties_cb) },
+ { "task-list-refresh",
+ GTK_STOCK_REFRESH,
+ N_("Re_fresh"),
+ NULL,
+ N_("Refresh the selected task list"),
+ G_CALLBACK (action_task_list_refresh_cb) },
+
{ "task-list-rename",
NULL,
N_("_Rename..."),
@@ -835,6 +871,10 @@ static EPopupActionEntry task_popup_entries[] = {
NULL,
"task-list-properties" },
+ { "task-list-popup-refresh",
+ NULL,
+ "task-list-refresh" },
+
{ "task-list-popup-rename",
NULL,
"task-list-rename" },
diff --git a/modules/calendar/e-task-shell-view-actions.h b/modules/calendar/e-task-shell-view-actions.h
index 6c2d5d5..3d49ff6 100644
--- a/modules/calendar/e-task-shell-view-actions.h
+++ b/modules/calendar/e-task-shell-view-actions.h
@@ -73,6 +73,8 @@
E_SHELL_WINDOW_ACTION ((window), "task-list-print-preview")
#define E_SHELL_WINDOW_ACTION_TASK_LIST_PROPERTIES(window) \
E_SHELL_WINDOW_ACTION ((window), "task-list-properties")
+#define E_SHELL_WINDOW_ACTION_TASK_LIST_REFRESH(window) \
+ E_SHELL_WINDOW_ACTION ((window), "task-list-refresh")
#define E_SHELL_WINDOW_ACTION_TASK_LIST_RENAME(window) \
E_SHELL_WINDOW_ACTION ((window), "task-list-rename")
#define E_SHELL_WINDOW_ACTION_TASK_LIST_SELECT_ONE(window) \
diff --git a/modules/calendar/e-task-shell-view.c b/modules/calendar/e-task-shell-view.c
index 8518a6d..9558eb7 100644
--- a/modules/calendar/e-task-shell-view.c
+++ b/modules/calendar/e-task-shell-view.c
@@ -291,6 +291,7 @@ task_shell_view_update_actions (EShellView *shell_view)
gboolean some_tasks_incomplete;
gboolean sources_are_editable;
gboolean clipboard_has_calendar;
+ gboolean refresh_supported;
priv = E_TASK_SHELL_VIEW_GET_PRIVATE (shell_view);
@@ -325,6 +326,8 @@ task_shell_view_update_actions (EShellView *shell_view)
(state & E_TASK_SHELL_SIDEBAR_CAN_DELETE_PRIMARY_SOURCE);
primary_source_is_system =
(state & E_TASK_SHELL_SIDEBAR_PRIMARY_SOURCE_IS_SYSTEM);
+ refresh_supported =
+ (state & E_TASK_SHELL_SIDEBAR_SOURCE_SUPPORTS_REFRESH);
any_tasks_selected =
(single_task_selected || multiple_tasks_selected);
@@ -372,6 +375,10 @@ task_shell_view_update_actions (EShellView *shell_view)
sensitive = has_primary_source;
gtk_action_set_sensitive (action, sensitive);
+ action = ACTION (TASK_LIST_REFRESH);
+ sensitive = refresh_supported;
+ gtk_action_set_sensitive (action, sensitive);
+
action = ACTION (TASK_LIST_RENAME);
sensitive = can_delete_primary_source;
gtk_action_set_sensitive (action, sensitive);
diff --git a/ui/evolution-calendars.ui b/ui/evolution-calendars.ui
index feb68db..8bff0fc 100644
--- a/ui/evolution-calendars.ui
+++ b/ui/evolution-calendars.ui
@@ -50,6 +50,7 @@
<menuitem action='calendar-new'/>
<menuitem action='calendar-popup-copy'/>
<menuitem action='calendar-popup-rename'/>
+ <menuitem action='calendar-popup-refresh'/>
<separator/>
<menuitem action='calendar-popup-delete'/>
<menuitem action='calendar-popup-select-one'/>
diff --git a/ui/evolution-memos.ui b/ui/evolution-memos.ui
index a303ae3..0d842b1 100644
--- a/ui/evolution-memos.ui
+++ b/ui/evolution-memos.ui
@@ -59,6 +59,7 @@
<menuitem action='memo-list-new'/>
<menuitem action='memo-list-popup-copy'/>
<menuitem action='memo-list-popup-rename'/>
+ <menuitem action='memo-list-popup-refresh'/>
<separator/>
<menuitem action='memo-list-popup-delete'/>
<menuitem action='memo-list-popup-select-one'/>
diff --git a/ui/evolution-tasks.ui b/ui/evolution-tasks.ui
index e2682b3..7069588 100644
--- a/ui/evolution-tasks.ui
+++ b/ui/evolution-tasks.ui
@@ -70,6 +70,7 @@
<menuitem action='task-list-new'/>
<menuitem action='task-list-popup-copy'/>
<menuitem action='task-list-popup-rename'/>
+ <menuitem action='task-list-popup-refresh'/>
<separator/>
<menuitem action='task-list-popup-delete'/>
<menuitem action='task-list-popup-select-one'/>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]