aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/tasks-component.c
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@ximian.com>2003-11-04 20:47:14 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2003-11-04 20:47:14 +0800
commit571d39604123bf34f1a8932b8e3671c63ca43c42 (patch)
tree4747865c4ac9de34ce9ecb63bde3d82c16c39782 /calendar/gui/tasks-component.c
parentde2131408dbcced673b45db2f57539847ba28291 (diff)
downloadgsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar.gz
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar.bz2
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar.lz
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar.xz
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.tar.zst
gsoc2013-evolution-571d39604123bf34f1a8932b8e3671c63ca43c42.zip
added more menu items. (delete_calendar_cb): callbacks for new popup menu
2003-11-04 Rodrigo Moya <rodrigo@ximian.com> * gui/calendar-component.c (fill_popup_menu_callback): added more menu items. (delete_calendar_cb): callbacks for new popup menu items. (impl_createControls): add the source selector widget to the CalendarComponentPrivate structure. * gui/migration.[ch] (migrate_old_tasks): new function to migrate old tasks setups. (process_old_dir): renamed and added a "filename" argument, so that the same function can be used for tasks and calendar directories. (migrate_old_calendars): added new argument when calling process_old_dir(). * gui/tasks-component.c (tasks_component_init): call migrate_old_tasks() if there are no groups defined. svn path=/trunk/; revision=23182
Diffstat (limited to 'calendar/gui/tasks-component.c')
-rw-r--r--calendar/gui/tasks-component.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/calendar/gui/tasks-component.c b/calendar/gui/tasks-component.c
index a6b7062b9c..4e5de7c692 100644
--- a/calendar/gui/tasks-component.c
+++ b/calendar/gui/tasks-component.c
@@ -305,14 +305,18 @@ tasks_component_init (TasksComponent *component, TasksComponentClass *klass)
group = e_source_group_new (_("On This Computer"), base_uri);
e_source_list_add_group (priv->source_list, group, -1);
- /* FIXME: migrate tasks from older setups */
- new_dir = g_build_filename (base_uri, "Personal/", NULL);
- if (!e_mkdir_hier (new_dir, 0700)) {
- source = e_source_new (_("Personal"), "Personal");
- e_source_group_add_source (group, source, -1);
+ /* migrate tasks from older setup */
+ if (!migrate_old_tasks (group)) {
+ /* create default tasks folders */
+ new_dir = g_build_filename (base_uri, "Personal/", NULL);
+ if (!e_mkdir_hier (new_dir, 0700)) {
+ source = e_source_new (_("Personal"), "Personal");
+ e_source_group_add_source (group, source, -1);
+ }
+
+ g_free (new_dir);
}
- g_free (new_dir);
g_free (base_uri);
}