aboutsummaryrefslogtreecommitdiffstats
path: root/shell
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2000-07-25 09:16:38 +0800
committerDan Winship <danw@src.gnome.org>2000-07-25 09:16:38 +0800
commitdbf077d9dd938f2aeccf6d907e5d87e106a92739 (patch)
treedef6aa8ce0d739b81c19256163a80ed543365eb3 /shell
parentb4fa8e15a8014442a0a21cc121cedda16cdc272a (diff)
downloadgsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar.gz
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar.bz2
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar.lz
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar.xz
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.tar.zst
gsoc2013-evolution-dbf077d9dd938f2aeccf6d907e5d87e106a92739.zip
Remove GOAD support.
* e-shell.c, main.c: Remove GOAD support. * evolution-shell-component-client.c: Remove GOAD support. (evolution_shell_component_client_new): Give the "maybe OAF_INFO_PATH" message if no oafinfo file was found, and give a "consult previous error messages" message if the component was found but not activated. Abort in either case. svn path=/trunk/; revision=4299
Diffstat (limited to 'shell')
-rw-r--r--shell/ChangeLog10
-rw-r--r--shell/e-shell.c6
-rw-r--r--shell/evolution-shell-component-client.c56
-rw-r--r--shell/main.c39
4 files changed, 27 insertions, 84 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index b43c61a1e4..562c5a5b3b 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,3 +1,13 @@
+2000-07-24 Dan Winship <danw@helixcode.com>
+
+ * e-shell.c, main.c: Remove GOAD support.
+
+ * evolution-shell-component-client.c: Remove GOAD support.
+ (evolution_shell_component_client_new): Give the "maybe
+ OAF_INFO_PATH" message if no oafinfo file was found, and give a
+ "consult previous error messages" message if the component was
+ found but not activated. Abort in either case.
+
2000-07-23 Ettore Perazzoli <ettore@helixcode.com>
* e-shell-view-menu.c: Converted to use `bonobo_ui_handler_*()'
diff --git a/shell/e-shell.c b/shell/e-shell.c
index 09ff9285fa..fd8807ab64 100644
--- a/shell/e-shell.c
+++ b/shell/e-shell.c
@@ -70,15 +70,9 @@ struct _EShellPrivate {
#define SHORTCUTS_FILE_NAME "shortcuts.xml"
#define LOCAL_STORAGE_DIRECTORY "local"
-#ifdef USING_OAF
#define MAIL_COMPONENT_ID "OAFIID:evolution-shell-component:evolution-mail:d3cb3ed6-a654-4337-8aa0-f443751d6d1b"
#define CALENDAR_COMPONENT_ID "OAFIID:evolution-shell-component:evolution-calendar:2eb9eb63-d305-4918-9c35-faae5db19e51"
#define ADDRESSBOOK_COMPONENT_ID "OAFIID:evolution-shell-component:addressbook:b7a26547-7014-4bb5-98ab-2bcac2bb55ca"
-#else
-#define MAIL_COMPONENT_ID "evolution-shell-component:evolution-mail"
-#define CALENDAR_COMPONENT_ID "evolution-shell-component:evolution-calendar"
-#define ADDRESSBOOK_COMPONENT_ID "evolution-shell-component:addressbook"
-#endif
enum {
diff --git a/shell/evolution-shell-component-client.c b/shell/evolution-shell-component-client.c
index 3a7ba57bbd..d805686518 100644
--- a/shell/evolution-shell-component-client.c
+++ b/shell/evolution-shell-component-client.c
@@ -31,6 +31,8 @@
#include <bonobo/bonobo-main.h>
#include <bonobo/bonobo-widget.h>
+#include <liboaf/liboaf.h>
+
#include "e-util/e-util.h"
#include "evolution-shell-component-client.h"
@@ -52,42 +54,6 @@ struct _EvolutionShellComponentClientPrivate {
g_return_val_if_fail ((cond), EVOLUTION_SHELL_COMPONENT_INVALIDARG)
-/* Object activation. */
-
-#ifdef USING_OAF
-
-#include <liboaf/liboaf.h>
-
-static CORBA_Object
-activate_object_from_id (const char *id)
-{
- CORBA_Environment ev;
- CORBA_Object corba_object;
-
- CORBA_exception_init (&ev);
-
- corba_object = oaf_activate_from_id ((char *) id, 0, NULL, &ev); /* Yuck. */
- if (ev._major != CORBA_NO_EXCEPTION)
- corba_object = CORBA_OBJECT_NIL;
-
- CORBA_exception_free (&ev);
-
- return corba_object;
-}
-
-#else
-
-#include <libgnorba/gnorba.h>
-
-static CORBA_Object
-activate_object_from_id (const char *id)
-{
- return goad_server_activate_with_id (NULL, id, 0, NULL);
-}
-
-#endif
-
-
/* Utility functions. */
static EvolutionShellComponentResult
@@ -350,21 +316,27 @@ EvolutionShellComponentClient *
evolution_shell_component_client_new (const char *id)
{
EvolutionShellComponentClient *new;
+ CORBA_Environment ev;
CORBA_Object corba_object;
g_return_val_if_fail (id != NULL, NULL);
- new = gtk_type_new (evolution_shell_component_client_get_type ());
+ CORBA_exception_init (&ev);
- corba_object = activate_object_from_id (id);
+ corba_object = oaf_activate_from_id ((char *) id, 0, NULL, &ev); /* Yuck. */
+ if (ev._major != CORBA_NO_EXCEPTION) {
+ CORBA_exception_free (&ev);
+ g_error ("Could not start up component for %s. "
+ "(See previous error messages?)", id);
+ }
+ CORBA_exception_free (&ev);
if (corba_object == CORBA_OBJECT_NIL) {
- g_warning ("Could not activate component %s. "
- "(Maybe you need to set OAF_INFO_PATH?)", id);
- bonobo_object_unref (BONOBO_OBJECT (new));
- return NULL;
+ g_error ("Could not activate component %s. "
+ "(Maybe you need to set OAF_INFO_PATH?)", id);
}
+ new = gtk_type_new (evolution_shell_component_client_get_type ());
evolution_shell_component_client_construct (new, corba_object);
return new;
diff --git a/shell/main.c b/shell/main.c
index e614a7ce83..cdad9f76c9 100644
--- a/shell/main.c
+++ b/shell/main.c
@@ -26,6 +26,7 @@
#include <bonobo.h>
#include <libgnomeui/gnome-window-icon.h>
#include <glade/glade.h>
+#include <liboaf/liboaf.h>
#include "e-util/e-gui-utils.h"
#include "e-setup.h"
@@ -49,41 +50,6 @@ destroy_cb (GtkObject *object, gpointer data)
gtk_main_quit ();
}
-#ifdef USING_OAF
-
-#include <liboaf/liboaf.h>
-
-static void
-init_corba (int *argc, char **argv)
-{
- gnome_init_with_popt_table ("Evolution", VERSION, *argc, argv, oaf_popt_options, 0, NULL);
-
- oaf_init (*argc, argv);
-}
-
-#else /* USING_OAF */
-
-#include <libgnorba/gnorba.h>
-
-static void
-init_corba (int *argc, char **argv)
-{
- CORBA_Environment ev;
-
- CORBA_exception_init (&ev);
-
- gnome_CORBA_init_with_popt_table ("Evolution", VERSION, argc, argv,
- NULL, 0, NULL,
- GNORBA_INIT_SERVER_FUNC, &ev);
-
- if (ev._major != CORBA_NO_EXCEPTION)
- g_error ("Cannot initialize GNOME");
-
- CORBA_exception_free (&ev);
-}
-
-#endif /* USING_OAF */
-
static void
development_warning ()
{
@@ -184,7 +150,8 @@ main (int argc, char **argv)
bindtextdomain (PACKAGE, EVOLUTION_LOCALEDIR);
textdomain (PACKAGE);
- init_corba (&argc, argv);
+ gnome_init_with_popt_table ("Evolution", VERSION, argc, argv, oaf_popt_options, 0, NULL);
+ oaf_init (argc, argv);
glade_gnome_init ();