aboutsummaryrefslogtreecommitdiffstats
path: root/composer/evolution-composer.c
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@helixcode.com>2001-01-12 07:20:37 +0800
committerMiguel de Icaza <miguel@src.gnome.org>2001-01-12 07:20:37 +0800
commitc6737bc9e8da67083a455a2b3f0e5704290ab06c (patch)
tree0174acc088461cdf45483090c4c8b29caac59f76 /composer/evolution-composer.c
parent5a405a2c31ce8e3a6e14ab991a3e019243c14292 (diff)
downloadgsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar.gz
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar.bz2
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar.lz
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar.xz
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.tar.zst
gsoc2013-evolution-c6737bc9e8da67083a455a2b3f0e5704290ab06c.zip
Add an ItemContainer Bonobo interface to allow client applications to
2001-01-10 Miguel de Icaza <miguel@helixcode.com> * evolution-composer.c (evolution_composer_construct): Add an ItemContainer Bonobo interface to allow client applications to locate the Message Composer component. svn path=/trunk/; revision=7416
Diffstat (limited to 'composer/evolution-composer.c')
-rw-r--r--composer/evolution-composer.c26
1 files changed, 25 insertions, 1 deletions
diff --git a/composer/evolution-composer.c b/composer/evolution-composer.c
index b4614d6c50..45a6949eb3 100644
--- a/composer/evolution-composer.c
+++ b/composer/evolution-composer.c
@@ -27,7 +27,7 @@
#include <camel/camel.h>
#include <gal/util/e-util.h>
#include <gal/widgets/e-gui-utils.h>
-
+#include <bonobo/bonobo-item-handler.h>
#include "evolution-composer.h"
#define PARENT_TYPE BONOBO_OBJECT_TYPE
@@ -247,15 +247,39 @@ init (EvolutionComposer *composer)
}
+static Bonobo_ItemContainer_ObjectList *
+enum_objects (BonoboItemHandler *handler, gpointer data, CORBA_Environment *ev)
+{
+#warning "This function is not implemented because enumObjects has a broken CORBA prototype");
+}
+
+static Bonobo_Unknown
+get_object (BonoboItemHandler *h, const char *item_name, gboolean only_if_exists,
+ gpointer data, CORBA_Environment *ev)
+{
+ EvolutionComposer *composer = data;
+
+ if (strcmp (item_name, "composer_window") == 0)
+ return bonobo_object_dup_ref (
+ BONOBO_OBJECT (composer->composer)->corba_objref, ev);
+
+ return CORBA_OBJECT_NIL;
+}
+
void
evolution_composer_construct (EvolutionComposer *composer,
GNOME_Evolution_Composer corba_object)
{
+ BonoboObject *item_handler;
+
g_return_if_fail (composer != NULL);
g_return_if_fail (EVOLUTION_IS_COMPOSER (composer));
g_return_if_fail (corba_object != CORBA_OBJECT_NIL);
bonobo_object_construct (BONOBO_OBJECT (composer), corba_object);
+
+ item_handler = bonobo_item_handler_new (enum_objects, get_object, composer);
+ bonobo_object_add_interface (BONOBO_OBJECT (composer), BONOBO_OBJECT (item_handler));
}
EvolutionComposer *