summaryrefslogtreecommitdiff
path: root/plugins/pychrysa/pychrysa.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/pychrysa/pychrysa.c')
-rw-r--r--plugins/pychrysa/pychrysa.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/plugins/pychrysa/pychrysa.c b/plugins/pychrysa/pychrysa.c
index 4d32ee1..7c082d6 100644
--- a/plugins/pychrysa/pychrysa.c
+++ b/plugins/pychrysa/pychrysa.c
@@ -59,6 +59,10 @@
DEFINE_CHRYSALIDE_ACTIVE_PLUGIN("PyChrysalide", "Provides bindings to Python", "0.1.0", PGA_PLUGIN_INIT);
+/* Note la nature du chargement */
+static bool _standalone = true;
+
+
/* Fournit la révision du programme global. */
static PyObject *py_chrysalide_revision(PyObject *, PyObject *);
@@ -395,6 +399,9 @@ PyMODINIT_FUNC PyInit_pychrysalide(void)
return NULL;
}
+ if (_standalone)
+ init_all_plugins();
+
return result;
}
@@ -533,6 +540,8 @@ G_MODULE_EXPORT bool chrysalide_plugin_init(GPluginModule *plugin)
/* Chargement du module pour Python */
+ _standalone = false;
+
ret = PyImport_AppendInittab("pychrysalide", &PyInit_pychrysalide);
if (ret == -1)