aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--calendar/gui/calendar-commands.c31
-rw-r--r--calendar/gui/calendar-component.c87
-rw-r--r--calendar/gui/e-cal-shell-view-actions.c52
-rw-r--r--calendar/gui/e-memo-shell-view-actions.c52
-rw-r--r--calendar/gui/e-task-shell-view-actions.c52
-rw-r--r--calendar/gui/memos-component.c78
-rw-r--r--calendar/gui/tasks-component.c78
-rw-r--r--calendar/gui/tasks-control.c19
-rw-r--r--shell/e-shell-module.c26
-rw-r--r--shell/e-shell-module.h1
-rw-r--r--ui/evolution-calendars.ui14
-rw-r--r--ui/evolution-memos.ui8
-rw-r--r--ui/evolution-tasks.ui8
13 files changed, 207 insertions, 299 deletions
diff --git a/calendar/gui/calendar-commands.c b/calendar/gui/calendar-commands.c
index cbeca7c9e3..3b619134be 100644
--- a/calendar/gui/calendar-commands.c
+++ b/calendar/gui/calendar-commands.c
@@ -582,35 +582,6 @@ static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB_END
};
-static EPixmap pixmaps [] = {
- E_PIXMAP ("/commands/CalendarPrev", "go-previous", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/CalendarPrint", "document-print", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/DeleteAllOccurrences", "edit-delete", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/DeleteOccurrence", "edit-delete", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/CalendarGoto", "go-jump", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/CalendarNext", "go-next", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/CalendarPrintPreview", "document-print-preview", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/Copy", "edit-copy", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/Cut", "edit-cut", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/Delete", "edit-delete", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/Paste", "edit-paste", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/CalendarToday", "go-today", E_ICON_SIZE_MENU),
-
- E_PIXMAP ("/Toolbar/Print", "document-print", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Delete", "edit-delete", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Prev", "go-previous", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Next", "go-next", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Goto", "go-jump", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/DayView", "view-calendar-day", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/WorkWeekView", "view-calendar-workweek", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/WeekView", "view-calendar-week", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/MonthView", "view-calendar-month", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/ListView", "view-calendar-list", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Today", "go-today", E_ICON_SIZE_LARGE_TOOLBAR),
-
- E_PIXMAP_END
-};
-
void
calendar_control_activate (BonoboControl *control,
GnomeCalendar *gcal)
@@ -642,8 +613,6 @@ calendar_control_activate (BonoboControl *control,
NULL);
g_free (xmlfile);
- e_pixmaps_update (uic, pixmaps);
-
gnome_calendar_setup_view_menus (gcal, uic);
g_signal_connect (gcal, "calendar_focus_change",
diff --git a/calendar/gui/calendar-component.c b/calendar/gui/calendar-component.c
index 5ba3b11e96..3b17466682 100644
--- a/calendar/gui/calendar-component.c
+++ b/calendar/gui/calendar-component.c
@@ -110,8 +110,6 @@ typedef struct
} CalendarComponentView;
struct _CalendarComponentPrivate {
- char *base_directory;
- char *config_directory;
GConfClient *gconf_client;
int gconf_notify_id;
@@ -1580,53 +1578,6 @@ impl_createView (PortableServer_Servant servant,
}
-static GNOME_Evolution_CreatableItemTypeList *
-impl__get_userCreatableItems (PortableServer_Servant servant,
- CORBA_Environment *ev)
-{
- GNOME_Evolution_CreatableItemTypeList *list = GNOME_Evolution_CreatableItemTypeList__alloc ();
-
- list->_length = 4;
- list->_maximum = list->_length;
- list->_buffer = GNOME_Evolution_CreatableItemTypeList_allocbuf (list->_length);
-
- CORBA_sequence_set_release (list, FALSE);
-
- list->_buffer[0].id = CREATE_EVENT_ID;
- list->_buffer[0].description = _("New appointment");
- list->_buffer[0].menuDescription = (char *) C_("New", "_Appointment");
- list->_buffer[0].tooltip = _("Create a new appointment");
- list->_buffer[0].menuShortcut = 'a';
- list->_buffer[0].iconName = "appointment-new";
- list->_buffer[0].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[1].id = CREATE_MEETING_ID;
- list->_buffer[1].description = _("New meeting");
- list->_buffer[1].menuDescription = (char *) C_("New", "M_eeting");
- list->_buffer[1].tooltip = _("Create a new meeting request");
- list->_buffer[1].menuShortcut = 'e';
- list->_buffer[1].iconName = "stock_new-meeting";
- list->_buffer[1].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[2].id = CREATE_ALLDAY_EVENT_ID;
- list->_buffer[2].description = _("New all day appointment");
- list->_buffer[2].menuDescription = (char *) C_("New", "All Day A_ppointment");
- list->_buffer[2].tooltip = _("Create a new all-day appointment");
- list->_buffer[2].menuShortcut = '\0';
- list->_buffer[2].iconName = "stock_new-24h-appointment";
- list->_buffer[2].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[3].id = CREATE_CALENDAR_ID;
- list->_buffer[3].description = _("New calendar");
- list->_buffer[3].menuDescription = (char *) C_("New", "Cale_ndar");
- list->_buffer[3].tooltip = _("Create a new calendar");
- list->_buffer[3].menuShortcut = '\0';
- list->_buffer[3].iconName = "x-office-calendar";
- list->_buffer[3].type = GNOME_Evolution_CREATABLE_FOLDER;
-
- return list;
-}
-
static void
impl_requestCreateItem (PortableServer_Servant servant,
const CORBA_char *item_type_name,
@@ -1704,8 +1655,6 @@ impl_finalize (GObject *object)
}
g_list_free (priv->views);
- g_free (priv->base_directory);
- g_free (priv->config_directory);
g_free (priv);
(* G_OBJECT_CLASS (parent_class)->finalize) (object);
@@ -1721,7 +1670,6 @@ calendar_component_class_init (CalendarComponentClass *class)
epv->upgradeFromVersion = impl_upgradeFromVersion;
epv->createView = impl_createView;
- epv->_get_userCreatableItems = impl__get_userCreatableItems;
epv->requestCreateItem = impl_requestCreateItem;
epv->handleURI = impl_handleURI;
@@ -1737,9 +1685,6 @@ calendar_component_init (CalendarComponent *component)
priv = g_new0 (CalendarComponentPrivate, 1);
- priv->base_directory = g_build_filename (e_get_user_data_dir (), "calendar", NULL);
- priv->config_directory = g_build_filename (priv->base_directory, "config", NULL);
-
/* EPFIXME: Should use a custom one instead? Also we should add
* calendar_component_peek_gconf_client(). */
priv->gconf_client = gconf_client_get_default ();
@@ -1760,38 +1705,6 @@ calendar_component_init (CalendarComponent *component)
/* Public API. */
-CalendarComponent *
-calendar_component_peek (void)
-{
- static CalendarComponent *component = NULL;
-
- if (component == NULL) {
- component = g_object_new (calendar_component_get_type (), NULL);
-
- if (g_mkdir_with_parents (calendar_component_peek_config_directory (component), 0777) != 0) {
- g_warning (G_STRLOC ": Cannot create directory %s: %s",
- calendar_component_peek_config_directory (component),
- g_strerror (errno));
- g_object_unref (component);
- component = NULL;
- }
- }
-
- return component;
-}
-
-const char *
-calendar_component_peek_base_directory (CalendarComponent *component)
-{
- return component->priv->base_directory;
-}
-
-const char *
-calendar_component_peek_config_directory (CalendarComponent *component)
-{
- return component->priv->config_directory;
-}
-
ESourceList *
calendar_component_peek_source_list (CalendarComponent *component)
{
diff --git a/calendar/gui/e-cal-shell-view-actions.c b/calendar/gui/e-cal-shell-view-actions.c
index 638dc58ad0..e4f9d351c5 100644
--- a/calendar/gui/e-cal-shell-view-actions.c
+++ b/calendar/gui/e-cal-shell-view-actions.c
@@ -21,6 +21,18 @@
#include "e-cal-shell-view-private.h"
static void
+action_calendar_copy_cb (GtkAction *action,
+ ECalShellView *cal_shell_view)
+{
+}
+
+static void
+action_calendar_delete_cb (GtkAction *action,
+ ECalShellView *cal_shell_view)
+{
+}
+
+static void
action_calendar_go_back_cb (GtkAction *action,
ECalShellView *cal_shell_view)
{
@@ -45,6 +57,12 @@ action_calendar_jump_to_cb (GtkAction *action,
}
static void
+action_calendar_new_cb (GtkAction *action,
+ ECalShellView *cal_shell_view)
+{
+}
+
+static void
action_calendar_print_cb (GtkAction *action,
ECalShellView *cal_shell_view)
{
@@ -57,6 +75,12 @@ action_calendar_print_preview_cb (GtkAction *action,
}
static void
+action_calendar_properties_cb (GtkAction *action,
+ ECalShellView *cal_shell_view)
+{
+}
+
+static void
action_calendar_purge_cb (GtkAction *action,
ECalShellView *cal_shell_view)
{
@@ -113,6 +137,20 @@ action_event_open_cb (GtkAction *action,
static GtkActionEntry calendar_entries[] = {
+ { "calendar-copy",
+ GTK_STOCK_COPY,
+ N_("_Copy..."),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_calendar_copy_cb) },
+
+ { "calendar-delete",
+ GTK_STOCK_DELETE,
+ NULL,
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_calendar_delete_cb) },
+
{ "calendar-go-back",
GTK_STOCK_GO_BACK,
N_("Previous"),
@@ -141,6 +179,13 @@ static GtkActionEntry calendar_entries[] = {
N_("Select a specific date"),
G_CALLBACK (action_calendar_jump_to_cb) },
+ { "calendar-new",
+ "x-office-calendar",
+ N_("_New Calendar"),
+ NULL,
+ N_("Create a new calendar"),
+ G_CALLBACK (action_calendar_new_cb) },
+
{ "calendar-print",
GTK_STOCK_PRINT,
NULL,
@@ -155,6 +200,13 @@ static GtkActionEntry calendar_entries[] = {
N_("Preview the calendar to be printed"),
G_CALLBACK (action_calendar_print_preview_cb) },
+ { "calendar-properties",
+ GTK_STOCK_PROPERTIES,
+ NULL,
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_calendar_properties_cb) },
+
{ "calendar-purge",
NULL,
N_("Purg_e"),
diff --git a/calendar/gui/e-memo-shell-view-actions.c b/calendar/gui/e-memo-shell-view-actions.c
index 5086c0bb69..0e574cc618 100644
--- a/calendar/gui/e-memo-shell-view-actions.c
+++ b/calendar/gui/e-memo-shell-view-actions.c
@@ -45,6 +45,30 @@ action_memo_delete_cb (GtkAction *action,
}
static void
+action_memo_list_copy_cb (GtkAction *action,
+ EMemoShellView *memo_shell_view)
+{
+}
+
+static void
+action_memo_list_delete_cb (GtkAction *action,
+ EMemoShellView *memo_shell_view)
+{
+}
+
+static void
+action_memo_list_new_cb (GtkAction *action,
+ EMemoShellView *memo_shell_view)
+{
+}
+
+static void
+action_memo_list_properties_cb (GtkAction *action,
+ EMemoShellView *memo_shell_view)
+{
+}
+
+static void
action_memo_open_cb (GtkAction *action,
EMemoShellView *memo_shell_view)
{
@@ -98,6 +122,34 @@ static GtkActionEntry memo_entries[] = {
N_("Delete selected memos"),
G_CALLBACK (action_memo_delete_cb) },
+ { "memo-list-copy",
+ GTK_STOCK_COPY,
+ N_("_Copy..."),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_memo_list_copy_cb) },
+
+ { "memo-list-delete",
+ GTK_STOCK_DELETE,
+ N_("_Delete"),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_memo_list_delete_cb) },
+
+ { "memo-list-new",
+ "stock_notes",
+ N_("_New Memo List"),
+ NULL,
+ N_("Create a new memo list"),
+ G_CALLBACK (action_memo_list_new_cb) },
+
+ { "memo-list-properties",
+ GTK_STOCK_PROPERTIES,
+ NULL,
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_memo_list_properties_cb) },
+
{ "memo-open",
NULL,
N_("Open Memo"),
diff --git a/calendar/gui/e-task-shell-view-actions.c b/calendar/gui/e-task-shell-view-actions.c
index 36d2d3a3d0..ccdf86cdd1 100644
--- a/calendar/gui/e-task-shell-view-actions.c
+++ b/calendar/gui/e-task-shell-view-actions.c
@@ -57,6 +57,30 @@ action_task_forward_cb (GtkAction *action,
}
static void
+action_task_list_copy_cb (GtkAction *action,
+ ETaskShellView *task_shell_view)
+{
+}
+
+static void
+action_task_list_delete_cb (GtkAction *action,
+ ETaskShellView *task_shell_view)
+{
+}
+
+static void
+action_task_list_new_cb (GtkAction *action,
+ ETaskShellView *task_shell_view)
+{
+}
+
+static void
+action_task_list_properties_cb (GtkAction *action,
+ ETaskShellView *task_shell_view)
+{
+}
+
+static void
action_task_mark_complete_cb (GtkAction *action,
ETaskShellView *task_shell_view)
{
@@ -136,6 +160,34 @@ static GtkActionEntry task_entries[] = {
NULL, /* XXX Add a tooltip! */
G_CALLBACK (action_task_forward_cb) },
+ { "task-list-copy",
+ GTK_STOCK_COPY,
+ N_("Copy..."),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_task_list_copy_cb) },
+
+ { "task-list-delete",
+ GTK_STOCK_DELETE,
+ N_("_Delete"),
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_task_list_delete_cb) },
+
+ { "task-list-new",
+ "stock_todo",
+ N_("_New Task List"),
+ NULL,
+ N_("Create a new task list"),
+ G_CALLBACK (action_task_list_new_cb) },
+
+ { "task-list-properties",
+ GTK_STOCK_PROPERTIES,
+ NULL,
+ NULL,
+ NULL, /* XXX Add a tooltip! */
+ G_CALLBACK (action_task_list_properties_cb) },
+
{ "task-mark-complete",
NULL,
N_("Mar_k as Complete"),
diff --git a/calendar/gui/memos-component.c b/calendar/gui/memos-component.c
index adf54c5c2d..e292e8a7da 100644
--- a/calendar/gui/memos-component.c
+++ b/calendar/gui/memos-component.c
@@ -105,8 +105,6 @@ typedef struct _MemosComponentView
} MemosComponentView;
struct _MemosComponentPrivate {
- char *base_directory;
- char *config_directory;
ESourceList *source_list;
GSList *source_selection;
@@ -1244,45 +1242,6 @@ impl_createView (PortableServer_Servant servant,
return BONOBO_OBJREF(ecv);
}
-static GNOME_Evolution_CreatableItemTypeList *
-impl__get_userCreatableItems (PortableServer_Servant servant,
- CORBA_Environment *ev)
-{
- GNOME_Evolution_CreatableItemTypeList *list = GNOME_Evolution_CreatableItemTypeList__alloc ();
-
- list->_length = 3;
- list->_maximum = list->_length;
- list->_buffer = GNOME_Evolution_CreatableItemTypeList_allocbuf (list->_length);
-
- CORBA_sequence_set_release (list, FALSE);
-
- list->_buffer[0].id = CREATE_MEMO_ID;
- list->_buffer[0].description = _("New memo");
- list->_buffer[0].menuDescription = (char *) C_("New", "Mem_o");
- list->_buffer[0].tooltip = _("Create a new memo");
- list->_buffer[0].menuShortcut = 'o';
- list->_buffer[0].iconName = "stock_insert-note";
- list->_buffer[0].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[1].id = CREATE_SHARED_MEMO_ID;
- list->_buffer[1].description = _("New shared memo");
- list->_buffer[1].menuDescription = (char *) C_("New", "_Shared memo");
- list->_buffer[1].tooltip = _("Create a shared new memo");
- list->_buffer[1].menuShortcut = 'h';
- list->_buffer[1].iconName = "stock_insert-note";
- list->_buffer[1].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[2].id = CREATE_MEMO_LIST_ID;
- list->_buffer[2].description = _("New memo list");
- list->_buffer[2].menuDescription = (char *) C_("New", "Memo li_st");
- list->_buffer[2].tooltip = _("Create a new memo list");
- list->_buffer[2].menuShortcut = '\0';
- list->_buffer[2].iconName = "stock_notes";
- list->_buffer[2].type = GNOME_Evolution_CREATABLE_FOLDER;
-
- return list;
-}
-
static void
impl_requestCreateItem (PortableServer_Servant servant,
const CORBA_char *item_type_name,
@@ -1358,8 +1317,6 @@ impl_finalize (GObject *object)
}
g_list_free (priv->views);
- g_free (priv->base_directory);
- g_free (priv->config_directory);
g_free (priv);
(* G_OBJECT_CLASS (parent_class)->finalize) (object);
@@ -1375,7 +1332,6 @@ memos_component_class_init (MemosComponentClass *klass)
epv->upgradeFromVersion = impl_upgradeFromVersion;
epv->createView = impl_createView;
- epv->_get_userCreatableItems = impl__get_userCreatableItems;
epv->requestCreateItem = impl_requestCreateItem;
object_class->dispose = impl_dispose;
@@ -1389,46 +1345,12 @@ memos_component_init (MemosComponent *component, MemosComponentClass *klass)
priv = g_new0 (MemosComponentPrivate, 1);
- priv->base_directory = g_build_filename (e_get_user_data_dir (), "memos", NULL);
- priv->config_directory = g_build_filename (priv->base_directory, "config", NULL);
-
component->priv = priv;
ensure_sources (component);
}
/* Public API */
-MemosComponent *
-memos_component_peek (void)
-{
- static MemosComponent *component = NULL;
-
- if (component == NULL) {
- component = g_object_new (memos_component_get_type (), NULL);
-
- if (g_mkdir_with_parents (component->priv->config_directory, 0777) != 0) {
- g_warning (G_STRLOC ": Cannot create directory %s: %s",
- component->priv->config_directory, g_strerror (errno));
- g_object_unref (component);
- component = NULL;
- }
- }
-
- return component;
-}
-
-const char *
-memos_component_peek_base_directory (MemosComponent *component)
-{
- return component->priv->base_directory;
-}
-
-const char *
-memos_component_peek_config_directory (MemosComponent *component)
-{
- return component->priv->config_directory;
-}
-
ESourceList *
memos_component_peek_source_list (MemosComponent *component)
{
diff --git a/calendar/gui/tasks-component.c b/calendar/gui/tasks-component.c
index ac272c83d1..80e36c0feb 100644
--- a/calendar/gui/tasks-component.c
+++ b/calendar/gui/tasks-component.c
@@ -104,8 +104,6 @@ typedef struct
} TasksComponentView;
struct _TasksComponentPrivate {
- char *base_directory;
- char *config_directory;
ESourceList *source_list;
GSList *source_selection;
@@ -1309,45 +1307,6 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
return;
}
-static GNOME_Evolution_CreatableItemTypeList *
-impl__get_userCreatableItems (PortableServer_Servant servant,
- CORBA_Environment *ev)
-{
- GNOME_Evolution_CreatableItemTypeList *list = GNOME_Evolution_CreatableItemTypeList__alloc ();
-
- list->_length = 3;
- list->_maximum = list->_length;
- list->_buffer = GNOME_Evolution_CreatableItemTypeList_allocbuf (list->_length);
-
- CORBA_sequence_set_release (list, FALSE);
-
- list->_buffer[0].id = CREATE_TASK_ID;
- list->_buffer[0].description = _("New task");
- list->_buffer[0].menuDescription = (char *) C_("New", "_Task");
- list->_buffer[0].tooltip = _("Create a new task");
- list->_buffer[0].menuShortcut = 't';
- list->_buffer[0].iconName = "stock_task";
- list->_buffer[0].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[1].id = CREATE_TASK_ASSIGNED_ID;
- list->_buffer[1].description = _("New assigned task");
- list->_buffer[1].menuDescription = (char *) C_("New", "Assigne_d Task");
- list->_buffer[1].tooltip = _("Create a new assigned task");
- list->_buffer[1].menuShortcut = '\0';
- list->_buffer[1].iconName = "stock_task";
- list->_buffer[1].type = GNOME_Evolution_CREATABLE_OBJECT;
-
- list->_buffer[2].id = CREATE_TASK_LIST_ID;
- list->_buffer[2].description = _("New task list");
- list->_buffer[2].menuDescription = (char *) C_("New", "Tas_k list");
- list->_buffer[2].tooltip = _("Create a new task list");
- list->_buffer[2].menuShortcut = '\0';
- list->_buffer[2].iconName = "stock_todo";
- list->_buffer[2].type = GNOME_Evolution_CREATABLE_FOLDER;
-
- return list;
-}
-
static void
impl_requestCreateItem (PortableServer_Servant servant,
const CORBA_char *item_type_name,
@@ -1421,8 +1380,6 @@ impl_finalize (GObject *object)
}
g_list_free (priv->views);
- g_free (priv->base_directory);
- g_free (priv->config_directory);
g_free (priv);
(* G_OBJECT_CLASS (parent_class)->finalize) (object);
@@ -1438,7 +1395,6 @@ tasks_component_class_init (TasksComponentClass *klass)
epv->upgradeFromVersion = impl_upgradeFromVersion;
epv->createView = impl_createView;
- epv->_get_userCreatableItems = impl__get_userCreatableItems;
epv->requestCreateItem = impl_requestCreateItem;
epv->handleURI = impl_handleURI;
@@ -1453,46 +1409,12 @@ tasks_component_init (TasksComponent *component, TasksComponentClass *klass)
priv = g_new0 (TasksComponentPrivate, 1);
- priv->base_directory = g_build_filename (e_get_user_data_dir (), "tasks", NULL);
- priv->config_directory = g_build_filename (priv->base_directory, "config", NULL);
-
component->priv = priv;
ensure_sources (component);
}
/* Public API */
-TasksComponent *
-tasks_component_peek (void)
-{
- static TasksComponent *component = NULL;
-
- if (component == NULL) {
- component = g_object_new (tasks_component_get_type (), NULL);
-
- if (g_mkdir_with_parents (component->priv->config_directory, 0777) != 0) {
- g_warning (G_STRLOC ": Cannot create directory %s: %s",
- component->priv->config_directory, g_strerror (errno));
- g_object_unref (component);
- component = NULL;
- }
- }
-
- return component;
-}
-
-const char *
-tasks_component_peek_base_directory (TasksComponent *component)
-{
- return component->priv->base_directory;
-}
-
-const char *
-tasks_component_peek_config_directory (TasksComponent *component)
-{
- return component->priv->config_directory;
-}
-
ESourceList *
tasks_component_peek_source_list (TasksComponent *component)
{
diff --git a/calendar/gui/tasks-control.c b/calendar/gui/tasks-control.c
index 26927cb412..40e5c1e107 100644
--- a/calendar/gui/tasks-control.c
+++ b/calendar/gui/tasks-control.c
@@ -249,23 +249,6 @@ static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB_END
};
-static EPixmap pixmaps [] = {
- E_PIXMAP ("/commands/TasksCopy", "edit-copy", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksCut", "edit-cut", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksDelete", "edit-delete", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksForward", "mail-forward", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksPaste", "edit-paste", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksPrint", "document-print", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/TasksPrintPreview", "document-print-preview", E_ICON_SIZE_MENU),
-
- E_PIXMAP ("/Toolbar/Cut", "edit-cut", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Copy", "edit-copy", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Paste", "edit-paste", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Print", "document-print", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/Delete", "edit-delete", E_ICON_SIZE_LARGE_TOOLBAR),
-
- E_PIXMAP_END
-};
void
tasks_control_activate (BonoboControl *control, ETasks *tasks)
{
@@ -299,8 +282,6 @@ tasks_control_activate (BonoboControl *control, ETasks *tasks)
NULL);
g_free (xmlfile);
- e_pixmaps_update (uic, pixmaps);
-
e_tasks_setup_view_menus (tasks, uic);
/* Signals from the tasks widget; also sensitize the menu items as appropriate */
diff --git a/shell/e-shell-module.c b/shell/e-shell-module.c
index 75dbc3756f..6d6849ee29 100644
--- a/shell/e-shell-module.c
+++ b/shell/e-shell-module.c
@@ -20,6 +20,7 @@
#include "e-shell-module.h"
+#include <errno.h>
#include <gmodule.h>
#include <glib/gi18n.h>
#include <e-util/e-util.h>
@@ -41,6 +42,7 @@ struct _EShellModulePrivate {
gchar *filename;
EShell *shell;
+ gchar *config_dir;
gchar *data_dir;
/* Initializes the loaded type module. */
@@ -287,6 +289,15 @@ e_shell_module_compare (EShellModule *shell_module_a,
}
const gchar *
+e_shell_module_get_config_dir (EShellModule *shell_module)
+{
+ g_return_val_if_fail (E_IS_SHELL_MODULE (shell_module), NULL);
+ g_return_val_if_fail (shell_module->priv->config_dir != NULL, NULL);
+
+ return shell_module->priv->config_dir;
+}
+
+const gchar *
e_shell_module_get_data_dir (EShellModule *shell_module)
{
g_return_val_if_fail (E_IS_SHELL_MODULE (shell_module), NULL);
@@ -355,6 +366,7 @@ e_shell_module_set_info (EShellModule *shell_module,
{
GTypeModule *type_module;
EShellModuleInfo *module_info;
+ const gchar *pathname;
g_return_if_fail (E_IS_SHELL_MODULE (shell_module));
g_return_if_fail (info != NULL);
@@ -375,7 +387,21 @@ e_shell_module_set_info (EShellModule *shell_module,
module_info->is_busy = info->is_busy;
module_info->shutdown = info->shutdown;
+ /* Determine the user data directory for this module. */
g_free (shell_module->priv->data_dir);
shell_module->priv->data_dir = g_build_filename (
e_get_user_data_dir (), module_info->name, NULL);
+
+ /* Determine the user configuration directory for this module. */
+ g_free (shell_module->priv->config_dir);
+ shell_module->priv->config_dir = g_build_filename (
+ shell_module->priv->data_dir, "config", NULL);
+
+ /* Create the user configuration directory for this module,
+ * which should also create the user data directory. */
+ pathname = shell_module->priv->config_dir;
+ if (g_mkdir_with_parents (pathname, 0777) != 0)
+ g_critical (
+ "Cannot create directory %s: %s",
+ pathname, g_strerror (errno));
}
diff --git a/shell/e-shell-module.h b/shell/e-shell-module.h
index 7e2722f210..d9baa84a9a 100644
--- a/shell/e-shell-module.h
+++ b/shell/e-shell-module.h
@@ -74,6 +74,7 @@ EShellModule * e_shell_module_new (EShell *shell,
const gchar *filename);
gint e_shell_module_compare (EShellModule *shell_module_a,
EShellModule *shell_module_b);
+const gchar * e_shell_module_get_config_dir (EShellModule *shell_module);
const gchar * e_shell_module_get_data_dir (EShellModule *shell_module);
const gchar * e_shell_module_get_filename (EShellModule *shell_module);
const gchar * e_shell_module_get_searches (EShellModule *shell_module);
diff --git a/ui/evolution-calendars.ui b/ui/evolution-calendars.ui
index 5bda2a179f..4643eefd7c 100644
--- a/ui/evolution-calendars.ui
+++ b/ui/evolution-calendars.ui
@@ -23,12 +23,6 @@
<menu action='view-menu'>
<menuitem action='calendar-go-today'/>
<menuitem action='calendar-jump-to'/>
- <separator/>
- <menuitem action='calendar-view-day'/>
- <menuitem action='calendar-view-workweek'/>
- <menuitem action='calendar-view-week'/>
- <menuitem action='calendar-view-month'/>
- <menuitem action='calendar-view-list'/>
</menu>
<placeholder name='custom-menus'>
<menu action='actions-menu'>
@@ -52,4 +46,12 @@
<toolitem action='calendar-view-month'/>
<toolitem action='calendar-view-list'/>
</toolbar>
+ <popup name='calendar-popup'>
+ <menuitem action='calendar-new'/>
+ <menuitem action='calendar-copy'/>
+ <separator/>
+ <menuitem action='calendar-delete'/>
+ <separator/>
+ <menuitem action='calendar-properties'/>
+ </popup>
</ui>
diff --git a/ui/evolution-memos.ui b/ui/evolution-memos.ui
index a2a70455ba..24b9ebf3cf 100644
--- a/ui/evolution-memos.ui
+++ b/ui/evolution-memos.ui
@@ -30,4 +30,12 @@
<toolitem action='memo-print'/>
<toolitem action='memo-delete'/>
</toolbar>
+ <popup name='memo-list-popup'>
+ <menuitem action='memo-list-new'/>
+ <menuitem action='memo-list-copy'/>
+ <separator/>
+ <menuitem action='memo-list-delete'/>
+ <separator/>
+ <menuitem action='memo-list-properties'/>
+ </popup>
</ui>
diff --git a/ui/evolution-tasks.ui b/ui/evolution-tasks.ui
index ccfccd77bf..83dc37c45d 100644
--- a/ui/evolution-tasks.ui
+++ b/ui/evolution-tasks.ui
@@ -39,4 +39,12 @@
<toolitem action='task-print'/>
<toolitem action='task-delete'/>
</toolbar>
+ <popup name='task-list-popup'>
+ <menuitem action='task-list-new'/>
+ <menuitem action='task-list-copy'/>
+ <separator/>
+ <menuitem action='task-list-delete'/>
+ <separator/>
+ <menuitem action='task-list-properties'/>
+ </popup>
</ui>