aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shortcuts.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2002-08-01 06:10:37 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2002-08-01 06:10:37 +0800
commit6d778b9fa21e33d502a6b6c98639cb19dd8becfb (patch)
tree438975cfcd79cab6af445bf294e024e26392ba03 /shell/e-shortcuts.c
parent57ced76e37818bd9700b6f257d1afc37ab67823b (diff)
downloadgsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar.gz
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar.bz2
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar.lz
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar.xz
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.tar.zst
gsoc2013-evolution-6d778b9fa21e33d502a6b6c98639cb19dd8becfb.zip
New, implement a right-click -> "Add Default Shortcuts" menu item.
* e-shortcuts-view.c (create_default_shortcuts_cb): New, implement a right-click -> "Add Default Shortcuts" menu item. (rename_group_cb): Remove double casts. *lol* * e-shortcuts.c (e_shortcuts_add_default_shortcuts): New. (e_shortcuts_add_default_group): Use e_shortcuts_add_default_shortcuts(). svn path=/trunk/; revision=17663
Diffstat (limited to 'shell/e-shortcuts.c')
-rw-r--r--shell/e-shortcuts.c33
1 files changed, 21 insertions, 12 deletions
diff --git a/shell/e-shortcuts.c b/shell/e-shortcuts.c
index 9b1a26cb79..8ad70eba0f 100644
--- a/shell/e-shortcuts.c
+++ b/shell/e-shortcuts.c
@@ -1043,36 +1043,45 @@ e_shortcuts_update_shortcut (EShortcuts *shortcuts,
void
-e_shortcuts_add_default_group (EShortcuts *shortcuts)
+e_shortcuts_add_default_shortcuts (EShortcuts *shortcuts,
+ int group_num)
{
char *utf;
- g_return_if_fail (shortcuts != NULL);
- g_return_if_fail (E_IS_SHORTCUTS (shortcuts));
-
- utf = e_utf8_from_locale_string (_("Shortcuts"));
- e_shortcuts_add_group (shortcuts, -1, utf);
- g_free (utf);
-
utf = e_utf8_from_locale_string (_("Summary"));
e_shortcuts_add_shortcut (shortcuts, 0, -1, E_SUMMARY_URI, utf, 0, "summary", NULL);
g_free (utf);
utf = e_utf8_from_locale_string (_("Inbox"));
- e_shortcuts_add_shortcut (shortcuts, 0, -1, E_LOCAL_INBOX_URI, utf, 0, "mail", "inbox");
+ e_shortcuts_add_shortcut (shortcuts, 0, -1, "default:mail", utf, 0, "mail", "inbox");
g_free (utf);
utf = e_utf8_from_locale_string (_("Calendar"));
- e_shortcuts_add_shortcut (shortcuts, 0, -1, E_LOCAL_CALENDAR_URI, utf, 0, "calendar", NULL);
+ e_shortcuts_add_shortcut (shortcuts, 0, -1, "default:calendar", utf, 0, "calendar", NULL);
g_free (utf);
utf = e_utf8_from_locale_string (_("Tasks"));
- e_shortcuts_add_shortcut (shortcuts, 0, -1, E_LOCAL_TASKS_URI, utf, 0, "tasks", NULL);
+ e_shortcuts_add_shortcut (shortcuts, 0, -1, "default:tasks", utf, 0, "tasks", NULL);
g_free (utf);
utf = e_utf8_from_locale_string (_("Contacts"));
- e_shortcuts_add_shortcut (shortcuts, 0, -1, E_LOCAL_CONTACTS_URI, utf, 0, "contacts", NULL);
+ e_shortcuts_add_shortcut (shortcuts, 0, -1, "default:contacts", utf, 0, "contacts", NULL);
+ g_free (utf);
+}
+
+void
+e_shortcuts_add_default_group (EShortcuts *shortcuts)
+{
+ char *utf;
+
+ g_return_if_fail (shortcuts != NULL);
+ g_return_if_fail (E_IS_SHORTCUTS (shortcuts));
+
+ utf = e_utf8_from_locale_string (_("Shortcuts"));
+ e_shortcuts_add_group (shortcuts, -1, utf);
g_free (utf);
+
+ e_shortcuts_add_default_shortcuts (shortcuts, -1);
}
void