[monkey-bubble: 166/753] Put this back. (libbonobo_module_info): Put this here since Michael



commit 6a6ed05297feb9bb2341ee46bbafc9ae964fef5d
Author: Martin Baulig <baulig suse de>
Date:   Wed Apr 18 16:35:03 2001 +0000

    Put this back. (libbonobo_module_info): Put this here since Michael
    
    2001-04-18  Martin Baulig  <baulig suse de>
    
    	* libgnome-init.c (gnome_oaf_module_info): Put this back.
    	(libbonobo_module_info): Put this here since Michael doesn't want to
    	have it in Bonobo.

 libgnome/ChangeLog    |    6 +++++
 libgnome/gnome-init.c |   56 +++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 62 insertions(+), 0 deletions(-)
---
diff --git a/libgnome/ChangeLog b/libgnome/ChangeLog
index ed25d70..0b53b89 100644
--- a/libgnome/ChangeLog
+++ b/libgnome/ChangeLog
@@ -1,3 +1,9 @@
+2001-04-18  Martin Baulig  <baulig suse de>
+
+	* libgnome-init.c (gnome_oaf_module_info): Put this back.
+	(libbonobo_module_info): Put this here since Michael doesn't want to
+	have it in Bonobo.
+
 2001-04-17  Martin Baulig  <baulig suse de>
 
 	* libgnome-init.c (gnome_oaf_module_info): Removed; this is in libbonobo.
diff --git a/libgnome/gnome-init.c b/libgnome/gnome-init.c
index f05d572..fd253b6 100644
--- a/libgnome/gnome-init.c
+++ b/libgnome/gnome-init.c
@@ -50,10 +50,40 @@ extern struct poptOption gconf_options[];
 #include <gobject/gvaluetypes.h>
 
 #include <liboaf/liboaf.h>
+#include <bonobo/libbonobo.h>
 
 #include <libgnomevfs/gnome-vfs-init.h>
 
 /*****************************************************************************
+ * oaf
+ *****************************************************************************/
+
+static void
+gnome_oaf_pre_args_parse (GnomeProgram *program, GnomeModuleInfo *mod_info)
+{
+    oaf_preinit (program, mod_info);
+}
+
+static void
+gnome_oaf_post_args_parse (GnomeProgram *program, GnomeModuleInfo *mod_info)
+{
+    int dumb_argc = 1;
+    char *dumb_argv[] = {NULL};
+
+    oaf_postinit (program, mod_info);
+
+    dumb_argv[0] = program_invocation_name;
+    (void) oaf_orb_init (&dumb_argc, dumb_argv);
+}
+
+GnomeModuleInfo gnome_oaf_module_info = {
+    "gnome-oaf", VERSION, N_("GNOME OAF Support"),
+    NULL,
+    gnome_oaf_pre_args_parse, gnome_oaf_post_args_parse,
+    oaf_popt_options
+};
+
+/*****************************************************************************
  * gconf
  *****************************************************************************/
 
@@ -247,6 +277,32 @@ GnomeModuleInfo gnome_gconf_module_info = {
 };
 
 /*****************************************************************************
+ * libbonobo
+ *****************************************************************************/
+
+static void
+libbonobo_post_args_parse (GnomeProgram *program, GnomeModuleInfo *mod_info)
+{
+    CORBA_ORB orb;
+
+    orb = oaf_orb_get ();
+
+    bonobo_init (orb, CORBA_OBJECT_NIL, CORBA_OBJECT_NIL);
+}
+
+static GnomeModuleRequirement libbonobo_requirements[] = {
+    { VERSION, &gnome_oaf_module_info },
+    { NULL, NULL }
+};
+
+GnomeModuleInfo libbonobo_module_info = {
+    "libbonobo", VERSION, N_("Bonobo"),
+    libbonobo_requirements,
+    NULL, libbonobo_post_args_parse, NULL,
+    NULL, NULL, NULL, NULL
+};
+
+/*****************************************************************************
  * libgnome
  *****************************************************************************/
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]