aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-tasks.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2008-09-30 00:14:46 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-09-30 00:14:46 +0800
commit098ea8aad8d3249d9faca5df5b4fe67b94ba660f (patch)
treec39d278f71283c9ebded47c606970404276b020f /calendar/gui/e-tasks.c
parentcb78b84aecf1c011e0b013cc94a079e2dc0eabbc (diff)
downloadgsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar.gz
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar.bz2
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar.lz
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar.xz
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.tar.zst
gsoc2013-evolution-098ea8aad8d3249d9faca5df5b4fe67b94ba660f.zip
Get Memos to come up. Doesn't really work yet, but the widgets are all there.
svn path=/branches/kill-bonobo/; revision=36491
Diffstat (limited to 'calendar/gui/e-tasks.c')
-rw-r--r--calendar/gui/e-tasks.c120
1 files changed, 0 insertions, 120 deletions
diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c
index e32b8ca66a..7860217045 100644
--- a/calendar/gui/e-tasks.c
+++ b/calendar/gui/e-tasks.c
@@ -1263,126 +1263,6 @@ e_tasks_delete_completed (ETasks *tasks)
g_free (sexp);
}
-/* Callback used from the view collection when we need to display a new view */
-static void
-display_view_cb (GalViewInstance *instance, GalView *view, gpointer data)
-{
- ETasks *tasks;
-
- tasks = E_TASKS (data);
-
- if (GAL_IS_VIEW_ETABLE (view)) {
- gal_view_etable_attach_table (GAL_VIEW_ETABLE (view), e_table_scrolled_get_table (E_TABLE_SCROLLED (E_CALENDAR_TABLE (tasks->priv->tasks_view)->etable)));
- }
-
- gtk_paned_set_position ((GtkPaned *)tasks->priv->paned, calendar_config_get_task_vpane_pos ());
-}
-
-/**
- * e_tasks_setup_view_menus:
- * @tasks: A tasks widget.
- * @uic: UI controller to use for the menus.
- *
- * Sets up the #GalView menus for a tasks control. This function should be
- * called from the Bonobo control activation callback for this tasks control.
- * Also, the menus should be discarded using e_tasks_discard_view_menus().
- **/
-void
-e_tasks_setup_view_menus (ETasks *tasks, BonoboUIComponent *uic)
-{
- ETasksPrivate *priv;
- GalViewFactory *factory;
- ETableSpecification *spec;
- char *dir0, *dir1, *filename;
- static GalViewCollection *collection = NULL;
-
- g_return_if_fail (tasks != NULL);
- g_return_if_fail (E_IS_TASKS (tasks));
- g_return_if_fail (uic != NULL);
- g_return_if_fail (BONOBO_IS_UI_COMPONENT (uic));
-
- priv = tasks->priv;
-
- g_return_if_fail (priv->view_instance == NULL);
-
- g_return_if_fail (priv->view_instance == NULL);
- g_return_if_fail (priv->view_menus == NULL);
-
- /* Create the view instance */
-
- if (collection == NULL) {
- collection = gal_view_collection_new ();
-
- gal_view_collection_set_title (collection, _("Tasks"));
-
- dir0 = g_build_filename (EVOLUTION_GALVIEWSDIR,
- "tasks",
- NULL);
- dir1 = g_build_filename (tasks_component_peek_base_directory (tasks_component_peek ()),
- "tasks", "views", NULL);
- gal_view_collection_set_storage_directories (collection,
- dir0,
- dir1);
- g_free (dir1);
- g_free (dir0);
-
- /* Create the views */
-
- spec = e_table_specification_new ();
- filename = g_build_filename (EVOLUTION_ETSPECDIR,
- "e-calendar-table.etspec",
- NULL);
- if (!e_table_specification_load_from_file (spec, filename))
- g_error ("Unable to load ETable specification file "
- "for tasks");
- g_free (filename);
-
- factory = gal_view_factory_etable_new (spec);
- g_object_unref (spec);
- gal_view_collection_add_factory (collection, factory);
- g_object_unref (factory);
-
- /* Load the collection and create the menus */
-
- gal_view_collection_load (collection);
- }
-
- priv->view_instance = gal_view_instance_new (collection, NULL);
-
- priv->view_menus = gal_view_menus_new (priv->view_instance);
- gal_view_menus_apply (priv->view_menus, uic, NULL);
- g_signal_connect (priv->view_instance, "display_view", G_CALLBACK (display_view_cb), tasks);
- display_view_cb (priv->view_instance, gal_view_instance_get_current_view (priv->view_instance), tasks);
-}
-
-/**
- * e_tasks_discard_view_menus:
- * @tasks: A tasks widget.
- *
- * Discards the #GalView menus used by a tasks control. This function should be
- * called from the Bonobo control deactivation callback for this tasks control.
- * The menus should have been set up with e_tasks_setup_view_menus().
- **/
-void
-e_tasks_discard_view_menus (ETasks *tasks)
-{
- ETasksPrivate *priv;
-
- g_return_if_fail (tasks != NULL);
- g_return_if_fail (E_IS_TASKS (tasks));
-
- priv = tasks->priv;
-
- g_return_if_fail (priv->view_instance != NULL);
- g_return_if_fail (priv->view_menus != NULL);
-
- g_object_unref (priv->view_instance);
- priv->view_instance = NULL;
-
- g_object_unref (priv->view_menus);
- priv->view_menus = NULL;
-}
-
void
e_tasks_open_task_id (ETasks *tasks,
const char *src_uid,