aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@novell.com>2010-05-19 22:22:23 +0800
committerMichael Meeks <michael.meeks@novell.com>2010-05-19 22:22:23 +0800
commit9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1 (patch)
treee4815398dbd17e1b87f8bf220b106e5a017e1179 /modules
parent2566a8549d7fd878226aeb9269f2d5871a5eddc2 (diff)
parentea1a5fca456b891f8bb9ab248ad65651b66b54b2 (diff)
downloadgsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar.gz
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar.bz2
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar.lz
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar.xz
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.tar.zst
gsoc2013-evolution-9a718fdc54a11ffc2dfe90a1c03d832fe151c2e1.zip
Merge commit 'origin/express2' into express2
Diffstat (limited to 'modules')
-rw-r--r--modules/calendar/e-memo-shell-view-actions.c19
-rw-r--r--modules/calendar/e-task-shell-view-actions.c19
-rw-r--r--modules/mail/e-mail-shell-view-actions.c2
3 files changed, 29 insertions, 11 deletions
diff --git a/modules/calendar/e-memo-shell-view-actions.c b/modules/calendar/e-memo-shell-view-actions.c
index a9b7fea82e..69bf9c5e8e 100644
--- a/modules/calendar/e-memo-shell-view-actions.c
+++ b/modules/calendar/e-memo-shell-view-actions.c
@@ -334,7 +334,6 @@ action_memo_new_cb (GtkAction *action,
EShellWindow *shell_window;
EMemoShellContent *memo_shell_content;
EMemoTable *memo_table;
- ECalModelComponent *comp_data;
ECal *client;
ECalComponent *comp;
CompEditor *editor;
@@ -348,11 +347,21 @@ action_memo_new_cb (GtkAction *action,
memo_table = e_memo_shell_content_get_memo_table (memo_shell_content);
list = e_memo_table_get_selected (memo_table);
- g_return_if_fail (list != NULL);
- comp_data = list->data;
- g_slist_free (list);
+ if (list == NULL) {
+ ECalModel *model;
+
+ model = e_memo_table_get_model (memo_table);
+ client = e_cal_model_get_default_client (model);
+ } else {
+ ECalModelComponent *comp_data;
+
+ comp_data = list->data;
+ client = comp_data->client;
+ g_slist_free (list);
+ }
+
+ g_return_if_fail (client != NULL);
- client = comp_data->client;
editor = memo_editor_new (client, shell, COMP_EDITOR_NEW_ITEM);
comp = cal_comp_memo_new_with_defaults (client);
comp_editor_edit_comp (editor, comp);
diff --git a/modules/calendar/e-task-shell-view-actions.c b/modules/calendar/e-task-shell-view-actions.c
index 0fd218c9e9..310200d6a7 100644
--- a/modules/calendar/e-task-shell-view-actions.c
+++ b/modules/calendar/e-task-shell-view-actions.c
@@ -402,7 +402,6 @@ action_task_new_cb (GtkAction *action,
EShellView *shell_view;
EShellWindow *shell_window;
ETaskShellContent *task_shell_content;
- ECalModelComponent *comp_data;
ETaskTable *task_table;
ECal *client;
ECalComponent *comp;
@@ -417,11 +416,21 @@ action_task_new_cb (GtkAction *action,
task_table = e_task_shell_content_get_task_table (task_shell_content);
list = e_task_table_get_selected (task_table);
- g_return_if_fail (list != NULL);
- comp_data = list->data;
- g_slist_free (list);
+ if (list == NULL) {
+ ECalModel *model;
+
+ model = e_task_table_get_model (task_table);
+ client = e_cal_model_get_default_client (model);
+ } else {
+ ECalModelComponent *comp_data;
+
+ comp_data = list->data;
+ client = comp_data->client;
+ g_slist_free (list);
+ }
+
+ g_return_if_fail (client != NULL);
- client = comp_data->client;
editor = task_editor_new (client, shell, COMP_EDITOR_NEW_ITEM);
comp = cal_comp_task_new_with_defaults (client);
comp_editor_edit_comp (editor, comp);
diff --git a/modules/mail/e-mail-shell-view-actions.c b/modules/mail/e-mail-shell-view-actions.c
index efd3f64d02..f534c2a276 100644
--- a/modules/mail/e-mail-shell-view-actions.c
+++ b/modules/mail/e-mail-shell-view-actions.c
@@ -913,7 +913,7 @@ static GtkActionEntry mail_entries[] = {
{ "mail-folder-mark-all-as-read",
"mail-read",
N_("Mar_k All Messages as Read"),
- NULL,
+ "<Control>slash",
N_("Mark all messages in the folder as read"),
G_CALLBACK (action_mail_folder_mark_all_as_read_cb) },