diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2003-10-22 02:49:34 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2003-10-22 02:49:34 +0800 |
commit | 653cfffc0e00dfb59b36813c1b45c53d3f773c65 (patch) | |
tree | 9b486d5e383ec1391d60973d9cc548be0ef6d9d5 /calendar/gui/main.c | |
parent | 0fb08f3ff81575a4749d851404233f34252dd2f2 (diff) | |
download | gsoc2013-evolution-653cfffc0e00dfb59b36813c1b45c53d3f773c65.tar.gz gsoc2013-evolution-653cfffc0e00dfb59b36813c1b45c53d3f773c65.tar.zst gsoc2013-evolution-653cfffc0e00dfb59b36813c1b45c53d3f773c65.zip |
Merge new-ui-branch to the trunk.
svn path=/trunk/; revision=22965
Diffstat (limited to 'calendar/gui/main.c')
-rw-r--r-- | calendar/gui/main.c | 28 |
1 files changed, 12 insertions, 16 deletions
diff --git a/calendar/gui/main.c b/calendar/gui/main.c index a15c0ef846..681417f1df 100644 --- a/calendar/gui/main.c +++ b/calendar/gui/main.c @@ -49,9 +49,9 @@ #include "tasks-control.h" -#define FACTORY_ID "OAFIID:GNOME_Evolution_Calendar_Factory" +#define FACTORY_ID "OAFIID:GNOME_Evolution_Calendar_Factory_2" -#define CALENDAR_COMPONENT_ID "OAFIID:GNOME_Evolution_Calendar_ShellComponent" +#define CALENDAR_COMPONENT_ID "OAFIID:GNOME_Evolution_Calendar_Component" #define CALENDAR_CONTROL_ID "OAFIID:GNOME_Evolution_Calendar_Control" #define TASKS_CONTROL_ID "OAFIID:GNOME_Evolution_Tasks_Control" #define ITIP_CONTROL_ID "OAFIID:GNOME_Evolution_Calendar_iTip_Control" @@ -155,23 +155,19 @@ factory (BonoboGenericFactory *factory, initialized = TRUE; } - if (strcmp (component_id, CALENDAR_COMPONENT_ID) == 0) - return calendar_component_get_object (); - if (strcmp (component_id, CALENDAR_CONTROL_ID) == 0) + if (strcmp (component_id, CALENDAR_COMPONENT_ID) == 0) { + BonoboObject *object = BONOBO_OBJECT (calendar_component_peek ()); + bonobo_object_ref (object); + return object; + } else if (strcmp (component_id, CALENDAR_CONTROL_ID) == 0) return BONOBO_OBJECT (control_factory_new_control ()); - if (strcmp (component_id, TASKS_CONTROL_ID) == 0) + else if (strcmp (component_id, TASKS_CONTROL_ID) == 0) return BONOBO_OBJECT (tasks_control_new ()); - if (strcmp (component_id, ITIP_CONTROL_ID) == 0) + else if (strcmp (component_id, ITIP_CONTROL_ID) == 0) return BONOBO_OBJECT (itip_bonobo_control_new ()); - if (strcmp (component_id, CONFIG_CONTROL_ID) == 0) { - extern EvolutionShellClient *global_shell_client; /* FIXME ugly */ - - if (global_shell_client == NULL) - return NULL; - else - return BONOBO_OBJECT (cal_prefs_dialog_new ()); - } - if (strcmp (component_id, COMP_EDITOR_FACTORY_ID) == 0) + else if (strcmp (component_id, CONFIG_CONTROL_ID) == 0) + return BONOBO_OBJECT (cal_prefs_dialog_new ()); + else if (strcmp (component_id, COMP_EDITOR_FACTORY_ID) == 0) return BONOBO_OBJECT (comp_editor_factory_fn ()); g_warning (FACTORY_ID ": Don't know what to do with %s", component_id); |