From c741f30353b11728b7352abe1f7194c3a1616864 Mon Sep 17 00:00:00 2001 From: Matthew Loper Date: Wed, 29 Mar 2000 04:47:57 +0000 Subject: + * wombat/Makefile.am: new file. + * wombat/wombat.gnorba: Cleaned up. + + * wombat/wombat.c (setup_pcs): filled in the rest. + + * e-table-text-model.c (e_table_text_model_destroy): made + assertion more accurate. svn path=/trunk/; revision=2244 --- wombat/wombat.c | 46 +++++++++++++++++++++++++++++++++++++--------- 1 file changed, 37 insertions(+), 9 deletions(-) (limited to 'wombat/wombat.c') diff --git a/wombat/wombat.c b/wombat/wombat.c index 034b97f478..9568ae1938 100644 --- a/wombat/wombat.c +++ b/wombat/wombat.c @@ -9,6 +9,10 @@ #include #include #include +#include +#include +#include +#include CORBA_Environment ev; CORBA_ORB orb; @@ -26,20 +30,45 @@ setup_pas (int argc, char **argv) pas_book_factory_activate (factory); } -#include "cal-factory.h" -#include "calobj.h" + static void setup_pcs (int argc, char **argv) { - CalFactory *factory; - - factory = cal_factory_new (); + int result; + CORBA_Object object; + CalFactory *factory = cal_factory_new (); + if (!factory) { g_message ("%s: %d: couldn't create a Calendar factory\n", __FILE__, __LINE__); } - - + + object = bonobo_object_corba_objref (BONOBO_OBJECT (factory)); + + CORBA_exception_init (&ev); + result = goad_server_register (CORBA_OBJECT_NIL, + object, + "evolution:calendar-factory", + "server", + &ev); + + if (ev._major != CORBA_NO_EXCEPTION || result == -1) { + + g_message ("create_cal_factory(): " + "could not register the calendar factory"); + bonobo_object_unref (BONOBO_OBJECT (factory)); + CORBA_exception_free (&ev); + + } else if (result == -2) { + + g_message ("create_cal_factory(): " + "a calendar factory is already registered"); + bonobo_object_unref (BONOBO_OBJECT (factory)); + CORBA_exception_free (&ev); + + } + + CORBA_exception_free (&ev); } static void @@ -47,7 +76,6 @@ setup_config (int argc, char **argv) { } -#include static void setup_vfs (int argc, char **argv) { @@ -57,7 +85,7 @@ setup_vfs (int argc, char **argv) } } -#include + static void init_bonobo (int argc, char **argv) { -- cgit