aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/component-factory.c
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@ximian.com>2001-08-15 21:57:37 +0800
committerFederico Mena Quintero <federico@src.gnome.org>2001-08-15 21:57:37 +0800
commitc4fb981151237aaad3678d5e20c614855e0a0c55 (patch)
tree0de680a70b315d9b6ac1cdfb7b6161441b962b4f /calendar/gui/component-factory.c
parent6c4bced5573dc3d8ebb040985bc1f112950dec6d (diff)
downloadgsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar.gz
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar.bz2
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar.lz
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar.xz
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.tar.zst
gsoc2013-evolution-c4fb981151237aaad3678d5e20c614855e0a0c55.zip
Add the user creatable items. The callback is not actually implemented
2001-08-15 Federico Mena Quintero <federico@ximian.com> * gui/component-factory.c (factory_fn): Add the user creatable items. The callback is not actually implemented yet; this is just to finalize the GUI. * gui/dialogs/cal-prefs-dialog.glade: Added an option to ask for confirmation when deleting items. Added underlined shortcuts (they may not all work currently). svn path=/trunk/; revision=12047
Diffstat (limited to 'calendar/gui/component-factory.c')
-rw-r--r--calendar/gui/component-factory.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/calendar/gui/component-factory.c b/calendar/gui/component-factory.c
index d3c5e1d513..1e2747c546 100644
--- a/calendar/gui/component-factory.c
+++ b/calendar/gui/component-factory.c
@@ -44,6 +44,10 @@
/* OAFIID for the component factory */
#define COMPONENT_FACTORY_ID "OAFIID:GNOME_Evolution_Calendar_ShellComponentFactory"
+/* IDs for user creatable items */
+#define CREATE_EVENT_ID "event"
+#define CREATE_TASK_ID "task"
+
static BonoboGenericFactory *factory = NULL;
char *evolution_dir;
@@ -339,6 +343,16 @@ owner_unset_cb (EvolutionShellComponent *shell_component,
gtk_main_quit ();
}
+/* Callback used when we must create a user-creatable item */
+static void
+sc_user_create_new_item_cb (EvolutionShellComponent *shell_component,
+ const char *id,
+ const char *parent_folder_physical_uri,
+ const char *parent_folder_type)
+{
+ /* FIXME */
+}
+
#if 0
static void
destroy_cb (EvolutionShellComponent *shell_component,
@@ -381,6 +395,23 @@ factory_fn (BonoboGenericFactory *factory,
shells = g_list_append (shells, shell_component);
#endif
+ /* User creatable items */
+
+ evolution_shell_component_add_user_creatable_item (shell_component,
+ CREATE_EVENT_ID,
+ _("Create a new appointment"),
+ _("New _Appointment"),
+ 'a');
+
+ evolution_shell_component_add_user_creatable_item (shell_component,
+ CREATE_TASK_ID,
+ _("Create a new task"),
+ _("New _Task"),
+ 't');
+
+ gtk_signal_connect (GTK_OBJECT (shell_component), "user_create_new_item",
+ GTK_SIGNAL_FUNC (sc_user_create_new_item_cb), NULL);
+
return BONOBO_OBJECT (shell_component);
}