summaryrefslogtreecommitdiff
path: root/plugins/dalvik
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2023-05-22 20:56:32 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2023-05-22 20:56:32 (GMT)
commite1a2823b5d831349467d309ce42d56055ec9c04f (patch)
treebc4dd464d10cd379622ceb361398895d59849409 /plugins/dalvik
parent15fb909bdd8ca0f37dd71da7427ea6bc6bb71cbb (diff)
Rely on GObject-introspection implementation for some registrations.
Diffstat (limited to 'plugins/dalvik')
-rw-r--r--plugins/dalvik/python/instruction.c5
-rw-r--r--plugins/dalvik/python/processor.c5
-rw-r--r--plugins/dalvik/python/v35/instruction.c5
-rw-r--r--plugins/dalvik/python/v35/processor.c5
4 files changed, 14 insertions, 6 deletions
diff --git a/plugins/dalvik/python/instruction.c b/plugins/dalvik/python/instruction.c
index c9d039f..a6d4ad4 100644
--- a/plugins/dalvik/python/instruction.c
+++ b/plugins/dalvik/python/instruction.c
@@ -102,7 +102,10 @@ bool register_python_dalvik_instruction(PyObject *module)
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_DALVIK_INSTRUCTION, type, get_python_arch_instruction_type()))
+ if (!ensure_python_arch_instruction_is_registered())
+ return false;
+
+ if (!register_class_for_pygobject(dict, G_TYPE_DALVIK_INSTRUCTION, type))
return false;
return true;
diff --git a/plugins/dalvik/python/processor.c b/plugins/dalvik/python/processor.c
index 26fd8b7..9885a04 100644
--- a/plugins/dalvik/python/processor.c
+++ b/plugins/dalvik/python/processor.c
@@ -100,7 +100,10 @@ bool register_python_dalvik_processor(PyObject *module)
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_DALVIK_PROCESSOR, type, get_python_arch_processor_type()))
+ if (!ensure_python_arch_processor_is_registered())
+ return false;
+
+ if (!register_class_for_pygobject(dict, G_TYPE_DALVIK_PROCESSOR, type))
return false;
return true;
diff --git a/plugins/dalvik/python/v35/instruction.c b/plugins/dalvik/python/v35/instruction.c
index f5ccc2c..7373e77 100644
--- a/plugins/dalvik/python/v35/instruction.c
+++ b/plugins/dalvik/python/v35/instruction.c
@@ -100,8 +100,9 @@ bool register_python_dalvik35_instruction(PyObject *module)
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_DALVIK35_INSTRUCTION,
- type, get_python_dalvik_instruction_type()))
+ /* TODO : ensure get_python_dalvik_instruction_type() */
+
+ if (!register_class_for_pygobject(dict, G_TYPE_DALVIK35_INSTRUCTION, type))
return false;
return true;
diff --git a/plugins/dalvik/python/v35/processor.c b/plugins/dalvik/python/v35/processor.c
index fea342b..8df8249 100644
--- a/plugins/dalvik/python/v35/processor.c
+++ b/plugins/dalvik/python/v35/processor.c
@@ -100,8 +100,9 @@ bool register_python_dalvik35_processor(PyObject *module)
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_DALVIK35_PROCESSOR,
- type, get_python_dalvik_processor_type()))
+ /* TODO : ensure get_python_dalvik_processor_type() */
+
+ if (!register_class_for_pygobject(dict, G_TYPE_DALVIK35_PROCESSOR, type))
return false;
return true;