r4685 - in trunk/src/host/pye17: ecore ecore_evas edje evas
marek at docs.openmoko.org
marek at docs.openmoko.org
Wed Oct 1 09:03:23 CEST 2008
Author: marek
Date: 2008-10-01 09:03:22 +0200 (Wed, 01 Oct 2008)
New Revision: 4685
Modified:
trunk/src/host/pye17/ecore/ecoremodule.c
trunk/src/host/pye17/ecore_evas/ecore_evasmodule.c
trunk/src/host/pye17/edje/edjemodule.c
trunk/src/host/pye17/evas/Makefile
trunk/src/host/pye17/evas/evasmodule.c
Log:
call init function on module load
Modified: trunk/src/host/pye17/ecore/ecoremodule.c
===================================================================
--- trunk/src/host/pye17/ecore/ecoremodule.c 2008-09-30 08:47:23 UTC (rev 4684)
+++ trunk/src/host/pye17/ecore/ecoremodule.c 2008-10-01 07:03:22 UTC (rev 4685)
@@ -17,6 +17,10 @@
ecore_register_classes(d);
if (PyErr_Occurred()) {
- Py_FatalError ("can't initialise module ecore");
+ Py_FatalError("can't register ecore functions");
}
+
+ if (ecore_init() != 1) {
+ Py_FatalError("can't initialise ecore module");
+ }
}
Modified: trunk/src/host/pye17/ecore_evas/ecore_evasmodule.c
===================================================================
--- trunk/src/host/pye17/ecore_evas/ecore_evasmodule.c 2008-09-30 08:47:23 UTC (rev 4684)
+++ trunk/src/host/pye17/ecore_evas/ecore_evasmodule.c 2008-10-01 07:03:22 UTC (rev 4685)
@@ -17,6 +17,10 @@
ecore_evas_register_classes(d);
if (PyErr_Occurred()) {
- Py_FatalError ("can't initialise module ecore_evas");
+ Py_FatalError("can't register ecore_evas functions");
}
+
+ if (ecore_evas_init() != 1) {
+ Py_FatalError("can't initialise module ecore_evas");
+ }
}
Modified: trunk/src/host/pye17/edje/edjemodule.c
===================================================================
--- trunk/src/host/pye17/edje/edjemodule.c 2008-09-30 08:47:23 UTC (rev 4684)
+++ trunk/src/host/pye17/edje/edjemodule.c 2008-10-01 07:03:22 UTC (rev 4685)
@@ -1,22 +1,25 @@
#include <pygobject.h>
-
-void edje_register_classes (PyObject *d);
+
+void edje_register_classes (PyObject *d);
extern PyMethodDef edje_functions[];
-
+
DL_EXPORT(void)
initedje(void)
{
PyObject *m, *d;
-
- init_pygobject ();
-
- m = Py_InitModule ("edje", edje_functions);
- d = PyModule_GetDict (m);
-
- edje_register_classes (d);
-
- if (PyErr_Occurred ()) {
- Py_FatalError ("can't initialise module edje");
+
+ init_pygobject();
+
+ m = Py_InitModule("edje", edje_functions);
+ d = PyModule_GetDict(m);
+
+ edje_register_classes(d);
+
+ if (PyErr_Occurred()) {
+ Py_FatalError("can't register edje functions");
}
+
+ if (edje_init() != 1) {
+ Py_FatalError("can't initialise edje module");
+ }
}
-
\ No newline at end of file
Modified: trunk/src/host/pye17/evas/Makefile
===================================================================
--- trunk/src/host/pye17/evas/Makefile 2008-09-30 08:47:23 UTC (rev 4684)
+++ trunk/src/host/pye17/evas/Makefile 2008-10-01 07:03:22 UTC (rev 4685)
@@ -19,10 +19,3 @@
clean:
rm -f *.o *~ evas.defs evas.c evas.so
-
-
-### may need later ??
-# --override evas.override --register evas_data.defs \
-#
-# evas_data.defs: $(CODEGEN_PATH)/h2def.py $(EVAS_PATH)/Evas.h $(EVAS_PATH)/Evas_Data.h
-# $(CODEGEN_PATH)/h2def.py $(EVAS_PATH)/Evas_Data.h > $@
Modified: trunk/src/host/pye17/evas/evasmodule.c
===================================================================
--- trunk/src/host/pye17/evas/evasmodule.c 2008-09-30 08:47:23 UTC (rev 4684)
+++ trunk/src/host/pye17/evas/evasmodule.c 2008-10-01 07:03:22 UTC (rev 4685)
@@ -17,6 +17,10 @@
evas_register_classes(d);
if (PyErr_Occurred()) {
- Py_FatalError ("can't initialise module evas");
+ Py_FatalError("can't register evas functions");
}
+
+ if (evas_init() != 1) {
+ Py_FatalError("can't initialise evas module");
+ }
}
More information about the commitlog
mailing list