summaryrefslogtreecommitdiff
path: root/src/lib/elementary/elm_box_eo.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/elementary/elm_box_eo.c')
-rw-r--r--src/lib/elementary/elm_box_eo.c199
1 files changed, 199 insertions, 0 deletions
diff --git a/src/lib/elementary/elm_box_eo.c b/src/lib/elementary/elm_box_eo.c
new file mode 100644
index 0000000..b99a6d1
--- /dev/null
+++ b/src/lib/elementary/elm_box_eo.c
@@ -0,0 +1,199 @@
1EWAPI const Efl_Event_Description _ELM_BOX_EVENT_CHILD_ADDED =
2 EFL_EVENT_DESCRIPTION("child,added");
3EWAPI const Efl_Event_Description _ELM_BOX_EVENT_CHILD_REMOVED =
4 EFL_EVENT_DESCRIPTION("child,removed");
5
6void _elm_box_homogeneous_set(Eo *obj, Elm_Box_Data *pd, Eina_Bool homogeneous);
7
8
9static Eina_Error
10__eolian_elm_box_homogeneous_set_reflect(Eo *obj, Eina_Value val)
11{
12 Eina_Error r = 0; Eina_Bool cval;
13 if (!eina_value_bool_convert(&val, &cval))
14 {
15 r = EINA_ERROR_VALUE_FAILED;
16 goto end;
17 }
18 elm_obj_box_homogeneous_set(obj, cval);
19 end:
20 eina_value_flush(&val);
21 return r;
22}
23
24EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_homogeneous_set, EFL_FUNC_CALL(homogeneous), Eina_Bool homogeneous);
25
26Eina_Bool _elm_box_homogeneous_get(const Eo *obj, Elm_Box_Data *pd);
27
28
29static Eina_Value
30__eolian_elm_box_homogeneous_get_reflect(Eo *obj)
31{
32 Eina_Bool val = elm_obj_box_homogeneous_get(obj);
33 return eina_value_bool_init(val);
34}
35
36EOAPI EFL_FUNC_BODY_CONST(elm_obj_box_homogeneous_get, Eina_Bool, 0);
37
38void _elm_box_align_set(Eo *obj, Elm_Box_Data *pd, double horizontal, double vertical);
39
40EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_align_set, EFL_FUNC_CALL(horizontal, vertical), double horizontal, double vertical);
41
42void _elm_box_align_get(const Eo *obj, Elm_Box_Data *pd, double *horizontal, double *vertical);
43
44EOAPI EFL_VOID_FUNC_BODYV_CONST(elm_obj_box_align_get, EFL_FUNC_CALL(horizontal, vertical), double *horizontal, double *vertical);
45
46void _elm_box_horizontal_set(Eo *obj, Elm_Box_Data *pd, Eina_Bool horizontal);
47
48
49static Eina_Error
50__eolian_elm_box_horizontal_set_reflect(Eo *obj, Eina_Value val)
51{
52 Eina_Error r = 0; Eina_Bool cval;
53 if (!eina_value_bool_convert(&val, &cval))
54 {
55 r = EINA_ERROR_VALUE_FAILED;
56 goto end;
57 }
58 elm_obj_box_horizontal_set(obj, cval);
59 end:
60 eina_value_flush(&val);
61 return r;
62}
63
64EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_horizontal_set, EFL_FUNC_CALL(horizontal), Eina_Bool horizontal);
65
66Eina_Bool _elm_box_horizontal_get(const Eo *obj, Elm_Box_Data *pd);
67
68
69static Eina_Value
70__eolian_elm_box_horizontal_get_reflect(Eo *obj)
71{
72 Eina_Bool val = elm_obj_box_horizontal_get(obj);
73 return eina_value_bool_init(val);
74}
75
76EOAPI EFL_FUNC_BODY_CONST(elm_obj_box_horizontal_get, Eina_Bool, 0);
77
78void _elm_box_padding_set(Eo *obj, Elm_Box_Data *pd, int horizontal, int vertical);
79
80EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_padding_set, EFL_FUNC_CALL(horizontal, vertical), int horizontal, int vertical);
81
82void _elm_box_padding_get(const Eo *obj, Elm_Box_Data *pd, int *horizontal, int *vertical);
83
84EOAPI EFL_VOID_FUNC_BODYV_CONST(elm_obj_box_padding_get, EFL_FUNC_CALL(horizontal, vertical), int *horizontal, int *vertical);
85
86Eina_List *_elm_box_children_get(const Eo *obj, Elm_Box_Data *pd);
87
88EOAPI EFL_FUNC_BODY_CONST(elm_obj_box_children_get, Eina_List *, NULL);
89
90void _elm_box_pack_end(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *subobj);
91
92EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_pack_end, EFL_FUNC_CALL(subobj), Efl_Canvas_Object *subobj);
93
94void _elm_box_unpack_all(Eo *obj, Elm_Box_Data *pd);
95
96EOAPI EFL_VOID_FUNC_BODY(elm_obj_box_unpack_all);
97
98void _elm_box_unpack(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *subobj);
99
100EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_unpack, EFL_FUNC_CALL(subobj), Efl_Canvas_Object *subobj);
101
102void _elm_box_pack_after(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *subobj, Efl_Canvas_Object *after);
103
104EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_pack_after, EFL_FUNC_CALL(subobj, after), Efl_Canvas_Object *subobj, Efl_Canvas_Object *after);
105
106void _elm_box_pack_start(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *subobj);
107
108EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_pack_start, EFL_FUNC_CALL(subobj), Efl_Canvas_Object *subobj);
109
110void _elm_box_recalculate(Eo *obj, Elm_Box_Data *pd);
111
112EOAPI EFL_VOID_FUNC_BODY(elm_obj_box_recalculate);
113
114void _elm_box_pack_before(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *subobj, Efl_Canvas_Object *before);
115
116EOAPI EFL_VOID_FUNC_BODYV(elm_obj_box_pack_before, EFL_FUNC_CALL(subobj, before), Efl_Canvas_Object *subobj, Efl_Canvas_Object *before);
117
118void _elm_box_clear(Eo *obj, Elm_Box_Data *pd);
119
120EOAPI EFL_VOID_FUNC_BODY(elm_obj_box_clear);
121
122Efl_Object *_elm_box_efl_object_constructor(Eo *obj, Elm_Box_Data *pd);
123
124
125void _elm_box_efl_canvas_group_group_calculate(Eo *obj, Elm_Box_Data *pd);
126
127
128Eina_Error _elm_box_efl_ui_widget_theme_apply(Eo *obj, Elm_Box_Data *pd);
129
130
131Eina_Bool _elm_box_efl_ui_widget_widget_sub_object_del(Eo *obj, Elm_Box_Data *pd, Efl_Canvas_Object *sub_obj);
132
133
134void _elm_box_efl_ui_focus_composition_prepare(Eo *obj, Elm_Box_Data *pd);
135
136
137static Eina_Bool
138_elm_box_class_initializer(Efl_Class *klass)
139{
140 const Efl_Object_Ops *opsp = NULL;
141
142 const Efl_Object_Property_Reflection_Ops *ropsp = NULL;
143
144#ifndef ELM_BOX_EXTRA_OPS
145#define ELM_BOX_EXTRA_OPS
146#endif
147
148 EFL_OPS_DEFINE(ops,
149 EFL_OBJECT_OP_FUNC(elm_obj_box_homogeneous_set, _elm_box_homogeneous_set),
150 EFL_OBJECT_OP_FUNC(elm_obj_box_homogeneous_get, _elm_box_homogeneous_get),
151 EFL_OBJECT_OP_FUNC(elm_obj_box_align_set, _elm_box_align_set),
152 EFL_OBJECT_OP_FUNC(elm_obj_box_align_get, _elm_box_align_get),
153 EFL_OBJECT_OP_FUNC(elm_obj_box_horizontal_set, _elm_box_horizontal_set),
154 EFL_OBJECT_OP_FUNC(elm_obj_box_horizontal_get, _elm_box_horizontal_get),
155 EFL_OBJECT_OP_FUNC(elm_obj_box_padding_set, _elm_box_padding_set),
156 EFL_OBJECT_OP_FUNC(elm_obj_box_padding_get, _elm_box_padding_get),
157 EFL_OBJECT_OP_FUNC(elm_obj_box_children_get, _elm_box_children_get),
158 EFL_OBJECT_OP_FUNC(elm_obj_box_pack_end, _elm_box_pack_end),
159 EFL_OBJECT_OP_FUNC(elm_obj_box_unpack_all, _elm_box_unpack_all),
160 EFL_OBJECT_OP_FUNC(elm_obj_box_unpack, _elm_box_unpack),
161 EFL_OBJECT_OP_FUNC(elm_obj_box_pack_after, _elm_box_pack_after),
162 EFL_OBJECT_OP_FUNC(elm_obj_box_pack_start, _elm_box_pack_start),
163 EFL_OBJECT_OP_FUNC(elm_obj_box_recalculate, _elm_box_recalculate),
164 EFL_OBJECT_OP_FUNC(elm_obj_box_pack_before, _elm_box_pack_before),
165 EFL_OBJECT_OP_FUNC(elm_obj_box_clear, _elm_box_clear),
166 EFL_OBJECT_OP_FUNC(efl_constructor, _elm_box_efl_object_constructor),
167 EFL_OBJECT_OP_FUNC(efl_canvas_group_calculate, _elm_box_efl_canvas_group_group_calculate),
168 EFL_OBJECT_OP_FUNC(efl_ui_widget_theme_apply, _elm_box_efl_ui_widget_theme_apply),
169 EFL_OBJECT_OP_FUNC(efl_ui_widget_sub_object_del, _elm_box_efl_ui_widget_widget_sub_object_del),
170 EFL_OBJECT_OP_FUNC(efl_ui_focus_composition_prepare, _elm_box_efl_ui_focus_composition_prepare),
171 ELM_BOX_EXTRA_OPS
172 );
173 opsp = &ops;
174
175 static const Efl_Object_Property_Reflection refl_table[] = {
176 {"homogeneous", __eolian_elm_box_homogeneous_set_reflect, __eolian_elm_box_homogeneous_get_reflect},
177 {"horizontal", __eolian_elm_box_horizontal_set_reflect, __eolian_elm_box_horizontal_get_reflect},
178 };
179 static const Efl_Object_Property_Reflection_Ops rops = {
180 refl_table, EINA_C_ARRAY_LENGTH(refl_table)
181 };
182 ropsp = &rops;
183
184 return efl_class_functions_set(klass, opsp, ropsp);
185}
186
187static const Efl_Class_Description _elm_box_class_desc = {
188 EO_VERSION,
189 "Elm.Box",
190 EFL_CLASS_TYPE_REGULAR,
191 sizeof(Elm_Box_Data),
192 _elm_box_class_initializer,
193 _elm_box_class_constructor,
194 NULL
195};
196
197EFL_DEFINE_CLASS(elm_box_class_get, &_elm_box_class_desc, EFL_UI_WIDGET_CLASS, EFL_UI_FOCUS_COMPOSITION_MIXIN, EFL_UI_LEGACY_INTERFACE, NULL);
198
199#include "elm_box_eo.legacy.c"