summaryrefslogtreecommitdiff
path: root/include/efl.c_eo.pxd
diff options
context:
space:
mode:
authorKai Huuhko <kai.huuhko@gmail.com>2014-04-05 03:13:15 +0300
committerKai Huuhko <kai.huuhko@gmail.com>2014-04-05 03:13:15 +0300
commitadf70fa26fcae845b0bc55c6eebcaeafadc4d1c7 (patch)
treec5bf8953e6b6081bb6542eb5372295875151df02 /include/efl.c_eo.pxd
parent1149c6ed91a5dcb6e23998ba112d9e3d20a5ceb9 (diff)
Remove const hacks
They were a workaround for limitations in Cython <0.18
Diffstat (limited to 'include/efl.c_eo.pxd')
-rw-r--r--include/efl.c_eo.pxd46
1 files changed, 19 insertions, 27 deletions
diff --git a/include/efl.c_eo.pxd b/include/efl.c_eo.pxd
index 5ce114d..7639c6d 100644
--- a/include/efl.c_eo.pxd
+++ b/include/efl.c_eo.pxd
@@ -15,10 +15,6 @@
15# You should have received a copy of the GNU Lesser General Public License 15# You should have received a copy of the GNU Lesser General Public License
16# along with this Python-EFL. If not, see <http://www.gnu.org/licenses/>. 16# along with this Python-EFL. If not, see <http://www.gnu.org/licenses/>.
17 17
18#from efl.eina cimport *
19
20from libc.string cimport const_char
21from libc.stdlib cimport const_void
22from efl.eina cimport Eina_Bool 18from efl.eina cimport Eina_Bool
23 19
24cdef extern from "Eo.h": 20cdef extern from "Eo.h":
@@ -26,16 +22,12 @@ cdef extern from "Eo.h":
26 # Structures 22 # Structures
27 # 23 #
28 ctypedef struct Eo 24 ctypedef struct Eo
29 ctypedef Eo const_Eo "const Eo"
30 25
31 ctypedef struct Eo_Class 26 ctypedef struct Eo_Class
32 ctypedef Eo_Class const_Eo_Class "const Eo_Class"
33 27
34 ctypedef struct Eo_Event_Description: 28 ctypedef struct Eo_Event_Description:
35 const_char *name 29 const char *name
36 const_char *doc 30 const char *doc
37
38 ctypedef Eo_Event_Description const_Eo_Event_Description "const Eo_Event_Description"
39 31
40 ctypedef unsigned int Eo_Op 32 ctypedef unsigned int Eo_Op
41 33
@@ -44,12 +36,12 @@ cdef extern from "Eo.h":
44 #################################################################### 36 ####################################################################
45 # Eo Events 37 # Eo Events
46 # 38 #
47 cdef const_Eo_Event_Description *EO_EV_DEL 39 cdef const Eo_Event_Description *EO_EV_DEL
48 40
49 #################################################################### 41 ####################################################################
50 # Other typedefs 42 # Other typedefs
51 # 43 #
52 ctypedef Eina_Bool (*Eo_Event_Cb)(void *data, Eo *obj, const_Eo_Event_Description *desc, void *event_info) 44 ctypedef Eina_Bool (*Eo_Event_Cb)(void *data, Eo *obj, const Eo_Event_Description *desc, void *event_info)
53 45
54 ctypedef void (*eo_base_data_free_func)(void *) 46 ctypedef void (*eo_base_data_free_func)(void *)
55 47
@@ -60,30 +52,30 @@ cdef extern from "Eo.h":
60 int eo_init() 52 int eo_init()
61 int eo_shutdown() 53 int eo_shutdown()
62 54
63 Eo *eo_add(const_Eo_Class *klass, Eo *parent, ...) 55 Eo *eo_add(const Eo_Class *klass, Eo *parent, ...)
64 Eo *eo_ref(const_Eo *obj) 56 Eo *eo_ref(const Eo *obj)
65 void eo_unref(const_Eo *obj) 57 void eo_unref(const Eo *obj)
66 int eo_ref_get(const_Eo *obj) 58 int eo_ref_get(const Eo *obj)
67 void eo_del(const_Eo *obj) 59 void eo_del(const Eo *obj)
68 60
69 Eo_Op eo_wref_add(Eo *obj) 61 Eo_Op eo_wref_add(Eo *obj)
70 62
71 Eina_Bool eo_do(Eo *obj, ...) 63 Eina_Bool eo_do(Eo *obj, ...)
72 Eina_Bool eo_class_do(Eo_Class *cls, ...) 64 Eina_Bool eo_class_do(Eo_Class *cls, ...)
73 const_Eo_Class *eo_base_class_get() 65 const Eo_Class *eo_base_class_get()
74 66
75 Eo_Op eo_base_data_set(const_char *key, const_void *data, eo_base_data_free_func free_func) 67 Eo_Op eo_base_data_set(const char *key, const void *data, eo_base_data_free_func free_func)
76 Eo_Op eo_base_data_get(const_char *key, void **data) 68 Eo_Op eo_base_data_get(const char *key, void **data)
77 Eo_Op eo_base_data_del(const_char *key) 69 Eo_Op eo_base_data_del(const char *key)
78 70
79 const_Eo_Class *eo_class_get(const_Eo *obj) 71 const Eo_Class *eo_class_get(const Eo *obj)
80 const_char *eo_class_name_get(const_Eo_Class *klass) 72 const char *eo_class_name_get(const Eo_Class *klass)
81 73
82 Eo_Op eo_parent_set(Eo *parent) 74 Eo_Op eo_parent_set(Eo *parent)
83 Eo_Op eo_parent_get(Eo **parent) 75 Eo_Op eo_parent_get(Eo **parent)
84 76
85 Eo_Op eo_event_callback_forwarder_add(const_Eo_Event_Description *desc, Eo *new_obj) 77 Eo_Op eo_event_callback_forwarder_add(const Eo_Event_Description *desc, Eo *new_obj)
86 Eo_Op eo_event_callback_forwarder_del(const_Eo_Event_Description *desc, Eo *new_obj) 78 Eo_Op eo_event_callback_forwarder_del(const Eo_Event_Description *desc, Eo *new_obj)
87 79
88 Eo_Op eo_event_freeze() 80 Eo_Op eo_event_freeze()
89 Eo_Op eo_event_thaw() 81 Eo_Op eo_event_thaw()
@@ -93,5 +85,5 @@ cdef extern from "Eo.h":
93 Eo_Op eo_event_global_thaw() 85 Eo_Op eo_event_global_thaw()
94 Eo_Op eo_event_global_freeze_get(int *fcount) 86 Eo_Op eo_event_global_freeze_get(int *fcount)
95 87
96 Eo_Op eo_event_callback_add(const_Eo_Event_Description *desc, Eo_Event_Cb cb, const_void *data) 88 Eo_Op eo_event_callback_add(const Eo_Event_Description *desc, Eo_Event_Cb cb, const void *data)
97 Eo_Op eo_event_callback_del(const_Eo_Event_Description *desc, Eo_Event_Cb cb, const_void *data) 89 Eo_Op eo_event_callback_del(const Eo_Event_Description *desc, Eo_Event_Cb cb, const void *data)