[gedit/eggplugins: 5/6] Remove egg_plugins_engine_get_default()
- From: Steve Frécinaux <sfre src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gedit/eggplugins: 5/6] Remove egg_plugins_engine_get_default()
- Date: Fri, 9 Oct 2009 18:04:24 +0000 (UTC)
commit 558cff881067b4afc46d1fdb93d0b35173dff484
Author: Steve Frécinaux <code istique net>
Date: Fri Oct 9 18:54:25 2009 +0200
Remove egg_plugins_engine_get_default()
An equivalent to this should be implemented in the app.
Reason is that we are going to add construction properties that cannot
be known by the library, so "default" construction is not possible.
libplugins/egg-plugins-engine.c | 14 --------------
libplugins/egg-plugins-engine.h | 5 +----
2 files changed, 1 insertions(+), 18 deletions(-)
---
diff --git a/libplugins/egg-plugins-engine.c b/libplugins/egg-plugins-engine.c
index be64baa..3da12c9 100644
--- a/libplugins/egg-plugins-engine.c
+++ b/libplugins/egg-plugins-engine.c
@@ -80,8 +80,6 @@ struct _EggPluginsEnginePrivate
gboolean activate_from_prefs;
};
-EggPluginsEngine *default_engine = NULL;
-
static void egg_plugins_engine_activate_plugin_real (EggPluginsEngine *engine,
EggPluginsInfo *info);
static void egg_plugins_engine_deactivate_plugin_real (EggPluginsEngine *engine,
@@ -477,18 +475,6 @@ get_plugin_loader (EggPluginsEngine *engine, EggPluginsInfo *info)
return loader_info->loader;
}
-EggPluginsEngine *
-egg_plugins_engine_get_default (void)
-{
- if (default_engine != NULL)
- return default_engine;
-
- default_engine = EGG_PLUGINS_ENGINE (g_object_new (EGG_PLUGINS_TYPE_ENGINE, NULL));
- g_object_add_weak_pointer (G_OBJECT (default_engine),
- (gpointer) &default_engine);
- return default_engine;
-}
-
const GList *
egg_plugins_engine_get_plugin_list (EggPluginsEngine *engine)
{
diff --git a/libplugins/egg-plugins-engine.h b/libplugins/egg-plugins-engine.h
index 6dba29e..0c3f850 100644
--- a/libplugins/egg-plugins-engine.h
+++ b/libplugins/egg-plugins-engine.h
@@ -46,7 +46,7 @@ G_BEGIN_DECLS
#define EGG_PLUGINS_ENGINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EGG_PLUGINS_TYPE_ENGINE, EggPluginsEngineClass))
typedef struct _EggPluginsEngine EggPluginsEngine;
-typedef struct _EggPluginsEnginePrivate EggPluginsEnginePrivate;
+typedef struct _EggPluginsEnginePrivate EggPluginsEnginePrivate;
struct _EggPluginsEngine
{
@@ -69,9 +69,6 @@ struct _EggPluginsEngineClass
GType egg_plugins_engine_get_type (void) G_GNUC_CONST;
-EggPluginsEngine
- *egg_plugins_engine_get_default (void);
-
void egg_plugins_engine_garbage_collect (EggPluginsEngine *engine);
const GList *egg_plugins_engine_get_plugin_list (EggPluginsEngine *engine);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]