aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-config.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2009-08-29 08:21:54 +0800
committerMatthew Barnes <mbarnes@redhat.com>2009-08-30 05:23:20 +0800
commit32f545cdf031ebe3718791f18e8fb6b6141fd081 (patch)
tree980723161c32da855ca91b135318d7fa67dc18c7 /mail/em-config.c
parente8382099228d46ebef684c5384bab6ec710283ce (diff)
downloadgsoc2013-evolution-32f545cdf031ebe3718791f18e8fb6b6141fd081.tar.gz
gsoc2013-evolution-32f545cdf031ebe3718791f18e8fb6b6141fd081.tar.zst
gsoc2013-evolution-32f545cdf031ebe3718791f18e8fb6b6141fd081.zip
Simplify EPlugin loading at startup.
- Require all EPlugin and EPluginHook subtypes be registered before loading plugins. This drastically simplifies the EPlugin/EPluginHook negotiation. - Turn most EPluginHook subtypes into GTypeModules and register their types from an e_module_load() function (does not include shell hooks). - Convert EPluginLib and the Mono and Python bindings to GTypeModules and register their types from an e_module_load() function, and kill EPluginTypeHook.
Diffstat (limited to 'mail/em-config.c')
-rw-r--r--mail/em-config.c82
1 files changed, 0 insertions, 82 deletions
diff --git a/mail/em-config.c b/mail/em-config.c
index 357e88555b..dcdf9b10ef 100644
--- a/mail/em-config.c
+++ b/mail/em-config.c
@@ -223,85 +223,3 @@ em_config_target_new_account(EMConfig *emp, struct _EAccount *account)
return t;
}
-
-/* ********************************************************************** */
-
-/* Popup menu plugin handler */
-
-/*
-<e-plugin
- class="org.gnome.mail.plugin.popup:1.0"
- id="org.gnome.mail.plugin.popup.item:1.0"
- type="shlib"
- location="/opt/gnome2/lib/camel/1.0/libcamelimap.so"
- name="imap"
- description="IMAP4 and IMAP4v1 mail store">
- <hook class="org.gnome.mail.popupMenu:1.0"
- handler="HandlePopup">
- <menu id="any" target="select">
- <item
- type="item|toggle|radio|image|submenu|bar"
- active
- path="foo/bar"
- label="label"
- icon="foo"
- mask="select_one"
- activate="emp_view_emacs"/>
- </menu>
- </extension>
-
-*/
-
-static gpointer emph_parent_class;
-#define emph ((EMConfigHook *)eph)
-
-static const EConfigHookTargetMask emph_no_masks[] = {
- { NULL }
-};
-
-static const EConfigHookTargetMap emph_targets[] = {
- { "folder", EM_CONFIG_TARGET_FOLDER, emph_no_masks },
- { "prefs", EM_CONFIG_TARGET_PREFS, emph_no_masks },
- { "account", EM_CONFIG_TARGET_ACCOUNT, emph_no_masks },
- { NULL }
-};
-
-static void
-emph_finalise(GObject *o)
-{
- /*EPluginHook *eph = (EPluginHook *)o;*/
-
- ((GObjectClass *)emph_parent_class)->finalize(o);
-}
-
-static void
-emph_class_init(EPluginHookClass *klass)
-{
- gint i;
-
- ((GObjectClass *)klass)->finalize = emph_finalise;
- ((EPluginHookClass *)klass)->id = "org.gnome.evolution.mail.config:1.0";
-
- for (i=0;emph_targets[i].type;i++)
- e_config_hook_class_add_target_map((EConfigHookClass *)klass, &emph_targets[i]);
-
- ((EConfigHookClass *)klass)->config_class = g_type_class_ref(em_config_get_type());
-}
-
-GType
-em_config_hook_get_type(void)
-{
- static GType type = 0;
-
- if (!type) {
- static const GTypeInfo info = {
- sizeof(EMConfigHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
- sizeof(EMConfigHook), 0, (GInstanceInitFunc) NULL,
- };
-
- emph_parent_class = g_type_class_ref(e_config_hook_get_type());
- type = g_type_register_static(e_config_hook_get_type(), "EMConfigHook", &info, 0);
- }
-
- return type;
-}