diff options
Diffstat (limited to 'plugins/pychrysalide/helpers.c')
-rw-r--r-- | plugins/pychrysalide/helpers.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/plugins/pychrysalide/helpers.c b/plugins/pychrysalide/helpers.c index 6e13d3c..59bcd45 100644 --- a/plugins/pychrysalide/helpers.c +++ b/plugins/pychrysalide/helpers.c @@ -941,6 +941,37 @@ bool register_class_for_dynamic_pygobject(GType gtype, PyTypeObject *type, PyTyp } +/****************************************************************************** +* * +* Paramètres : self = objet Python/GObject à initialiser. * +* * +* Description : Fait suivre à la partie GObject une initialisation nouvelle. * +* * +* Retour : Bilan de l'opération. * +* * +* Remarques : - * +* * +******************************************************************************/ + +int forward_pygobjet_init(PyObject *self) +{ + bool result; /* Bilan à retourner */ + PyObject *new_args; /* Nouveaux arguments épurés */ + PyObject *new_kwds; /* Nouveau dictionnaire épuré */ + + new_args = PyTuple_New(0); + new_kwds = PyDict_New(); + + result = PyGObject_Type.tp_init(self, new_args, new_kwds); + + Py_DECREF(new_kwds); + Py_DECREF(new_args); + + return result; + +} + + /* ---------------------------------------------------------------------------------- */ /* TRANSFERT DES VALEURS CONSTANTES */ |