From 131a11a8a67c8d944a77227f7bed35aee1a127cb Mon Sep 17 00:00:00 2001 From: Sankar P Date: Fri, 26 Oct 2007 10:54:17 +0000 Subject: ** Fix for bug #461272 2007-10-26 Sankar P ** Fix for bug #461272 * plugin-manager.c: (eppm_selection_changed), (org_gnome_plugin_manager_manage): Configure button should not be enabled for all. configure button needs a hot-key. svn path=/trunk/; revision=34432 --- e-util/ChangeLog | 9 +++++++++ e-util/e-plugin.c | 21 ++++++++++++++++++--- e-util/e-plugin.h | 3 +++ 3 files changed, 30 insertions(+), 3 deletions(-) (limited to 'e-util') diff --git a/e-util/ChangeLog b/e-util/ChangeLog index ccb45fed49..dbf484b09f 100644 --- a/e-util/ChangeLog +++ b/e-util/ChangeLog @@ -1,3 +1,12 @@ +2007-10-26 Sankar P + + ** Fix for bug #461272 + + * e-plugin.c: (ep_load), (e_plugin_load_plugins), + (e_plugin_is_configurable), (epl_configure): + * e-plugin.h: + Configure button should not be enabled for all. + 2007-10-26 Kjartan Maraas * e-config.c: diff --git a/e-util/e-plugin.c b/e-util/e-plugin.c index edcdb4d43c..bdfe12c9b1 100644 --- a/e-util/e-plugin.c +++ b/e-util/e-plugin.c @@ -929,8 +929,8 @@ epl_construct(EPlugin *ep, xmlNodePtr root) return 0; } -static void -epl_configure (EPlugin *ep) +gboolean +e_plugin_is_configurable (EPlugin *ep) { EPluginLibConfigureFunc configure; @@ -938,9 +938,24 @@ epl_configure (EPlugin *ep) if (epl_loadmodule(ep) != 0) { pd(printf ("\n epl_loadmodule \n")); - return; + return FALSE; + } + + if (g_module_symbol(epl->module, "e_plugin_lib_configure", (void *)&configure)) { + pd(printf ("\n g_module_symbol is loaded\n")); + return TRUE; } + return FALSE; +} + +static void +epl_configure (EPlugin *ep) +{ + EPluginLibConfigureFunc configure; + + pd(printf ("\n epl_configure \n")); + /* Probably we dont need a load_module */ if (g_module_symbol(epl->module, "e_plugin_lib_configure", (void *)&configure)) { pd(printf ("\n g_module_symbol is loaded\n")); configure (epl); diff --git a/e-util/e-plugin.h b/e-util/e-plugin.h index eeda139878..e1dc1f29fd 100644 --- a/e-util/e-plugin.h +++ b/e-util/e-plugin.h @@ -101,6 +101,8 @@ void *e_plugin_invoke(EPlugin *ep, const char *name, void *data); void e_plugin_enable(EPlugin *eph, int state); void e_plugin_configure (EPlugin *eph); +gboolean e_plugin_is_configurable (EPlugin *ep); + /* static helpers */ /* maps prop or content to 'g memory' */ char *e_plugin_xml_prop(xmlNodePtr node, const char *id); @@ -274,3 +276,4 @@ struct _EPluginTypeHookClass { GType e_plugin_type_hook_get_type(void); #endif /* ! _E_PLUGIN_H */ + -- cgit