aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2008-11-14 11:56:01 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-11-14 11:56:01 +0800
commit8c0bd86d5fdd6d87c3170e2a01423e7c7018a981 (patch)
tree22da2df051cb6f1bc988d15aca08ebb0a5baf7e4 /shell/e-shell.c
parent6760cc72334346b8654fcd9fe1440890db55ac1b (diff)
downloadgsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar.gz
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar.bz2
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar.lz
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar.xz
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.tar.zst
gsoc2013-evolution-8c0bd86d5fdd6d87c3170e2a01423e7c7018a981.zip
Rearranged some of the addressbook code to try and eliminate some circular
dependencies in our libraries. The circular dependency between the composer and the mail module is still causing me headaches. And it doesn't help that the addressbook and calendar also want to link to the composer. svn path=/branches/kill-bonobo/; revision=36782
Diffstat (limited to 'shell/e-shell.c')
-rw-r--r--shell/e-shell.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/shell/e-shell.c b/shell/e-shell.c
index c875dcb5cf..d6884b0a69 100644
--- a/shell/e-shell.c
+++ b/shell/e-shell.c
@@ -62,6 +62,7 @@ enum {
LAST_SIGNAL
};
+EShell *default_shell = NULL;
static gpointer parent_class;
static guint signals[LAST_SIGNAL];
@@ -362,8 +363,9 @@ shell_class_init (EShellClass *class)
G_OBJECT_CLASS_TYPE (object_class),
G_SIGNAL_RUN_FIRST | G_SIGNAL_DETAILED | G_SIGNAL_ACTION,
0, NULL, NULL,
- g_cclosure_marshal_VOID__VOID,
- G_TYPE_NONE, 0);
+ g_cclosure_marshal_VOID__POINTER,
+ G_TYPE_NONE, 1,
+ G_TYPE_POINTER);
signals[HANDLE_URI] = g_signal_new (
"handle-uri",
@@ -451,9 +453,12 @@ e_shell_get_type (void)
}
EShell *
-e_shell_new (gboolean online_mode)
+e_shell_get_default (void)
{
- return g_object_new (E_TYPE_SHELL, "online-mode", online_mode, NULL);
+ /* Emit a warning if we call this too early. */
+ g_return_val_if_fail (default_shell != NULL, NULL);
+
+ return default_shell;
}
GList *
@@ -626,7 +631,8 @@ e_shell_get_preferences_window (void)
void
e_shell_event (EShell *shell,
- const gchar *event_name)
+ const gchar *event_name,
+ gpointer event_data)
{
GQuark detail;
@@ -634,7 +640,7 @@ e_shell_event (EShell *shell,
g_return_if_fail (event_name != NULL);
detail = g_quark_from_string (event_name);
- g_signal_emit (shell, signals[EVENT], detail);
+ g_signal_emit (shell, signals[EVENT], detail, event_data);
}
gboolean