summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-10-13 18:16:41 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-10-13 18:36:51 +0900
commit2ac2bbf22010853f972263b32a3d705985fc5ba0 (patch)
tree64ff7b70e662561ad8ead3bdbf70fe80fcdd888b
parente91af478ef76d1498c529179e99ea7d8d71ca3cb (diff)
edje: Use EO's beta auto_unref API for partsdevs/jpeg/work
This simplifies code and avoids unwanted leaks.
-rw-r--r--src/lib/edje/edje_part.c93
-rw-r--r--src/lib/edje/edje_part_box.c52
-rw-r--r--src/lib/edje/edje_part_external.c2
-rw-r--r--src/lib/edje/edje_part_helper.h36
-rw-r--r--src/lib/edje/edje_part_swallow.c10
-rw-r--r--src/lib/edje/edje_part_table.c32
-rw-r--r--src/lib/edje/edje_part_text.c24
-rw-r--r--src/lib/edje/edje_private.h3
8 files changed, 99 insertions, 153 deletions
diff --git a/src/lib/edje/edje_part.c b/src/lib/edje/edje_part.c
index b3f9505217..741dcbef75 100644
--- a/src/lib/edje/edje_part.c
+++ b/src/lib/edje/edje_part.c
@@ -77,7 +77,7 @@ _edje_internal_proxy_shutdown(void)
77} 77}
78 78
79void 79void
80_edje_real_part_set(Eo *obj, Edje *ed, Edje_Real_Part *rp, const char *part) 80_edje_real_part_set(Eo *obj EINA_UNUSED, Edje *ed, Edje_Real_Part *rp, const char *part)
81{ 81{
82 Efl_Canvas_Layout_Part_Data *pd; 82 Efl_Canvas_Layout_Part_Data *pd;
83 83
@@ -86,147 +86,128 @@ _edje_real_part_set(Eo *obj, Edje *ed, Edje_Real_Part *rp, const char *part)
86 pd->ed = ed; 86 pd->ed = ed;
87 pd->rp = rp; 87 pd->rp = rp;
88 pd->part = part; 88 pd->part = part;
89 pd->temp = 1;
90 pd->in_use = 1;
91 pd->in_call = 0;
92 efl_parent_set(obj, ed->obj); 89 efl_parent_set(obj, ed->obj);
93} 90}
94 91
95EOLIAN static Efl_Object * 92EOLIAN static Efl_Object *
96_efl_canvas_layout_part_efl_object_finalize(Eo *obj, Efl_Canvas_Layout_Part_Data *pd) 93_efl_canvas_layout_part_efl_object_finalize(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd)
97{ 94{
98 EINA_SAFETY_ON_FALSE_RETURN_VAL(pd->rp && pd->ed && pd->part, NULL); 95 EINA_SAFETY_ON_FALSE_RETURN_VAL(pd->rp && pd->ed && pd->part, NULL);
99 // Do not use RETURN_VAL() here! 96 // Do not use return here!
100 return efl_finalize(efl_super(obj, MY_CLASS)); 97 return efl_finalize(efl_super(obj, MY_CLASS));
101} 98}
102 99
103EOLIAN Eina_Rect 100EOLIAN Eina_Rect
104_efl_canvas_layout_part_efl_gfx_geometry_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd) 101_efl_canvas_layout_part_efl_gfx_geometry_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd)
105{ 102{
106 Edje_Real_Part *rp = pd->rp; 103 Edje_Real_Part *rp = pd->rp;
107 Eina_Rect r = EINA_RECT_ZERO(); 104 Eina_Rect r = EINA_RECT_ZERO();
108 105
109 PROXY_CALL_BEGIN(pd);
110 _edje_recalc_do(pd->ed); 106 _edje_recalc_do(pd->ed);
111 if (!rp) RETURN_VAL(r); 107 if (!rp) return r;
112 108
113 RETURN_VAL((Eina_Rect) rp->rect); 109 return (Eina_Rect) rp->rect;
114} 110}
115 111
116EOLIAN static void 112EOLIAN static void
117_efl_canvas_layout_part_state_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, const char **name, double *val) 113_efl_canvas_layout_part_state_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, const char **name, double *val)
118{ 114{
119 const char *str; 115 const char *str;
120 PROXY_CALL_BEGIN(pd);
121 116
122 if (!name && !val) 117 if (!name && !val) return;
123 RETURN_VOID;
124 str = _edje_object_part_state_get(pd->ed, pd->part, val); 118 str = _edje_object_part_state_get(pd->ed, pd->part, val);
125 if (name) *name = str; 119 if (name) *name = str;
126 RETURN_VOID;
127} 120}
128 121
129EOLIAN static Efl_Canvas_Layout_Part_Type 122EOLIAN static Efl_Canvas_Layout_Part_Type
130_efl_canvas_layout_part_part_type_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd) 123_efl_canvas_layout_part_part_type_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd)
131{ 124{
132 Edje_Real_Part *rp; 125 Edje_Real_Part *rp;
133 PROXY_CALL_BEGIN(pd);
134 126
135 rp = _edje_real_part_recursive_get(&pd->ed, pd->part); 127 rp = _edje_real_part_recursive_get(&pd->ed, pd->part);
136 if (!rp || !rp->part) RETURN_VAL(EFL_CANVAS_LAYOUT_PART_TYPE_NONE); 128 if (!rp || !rp->part) return EFL_CANVAS_LAYOUT_PART_TYPE_NONE;
137 129
138 RETURN_VAL((Efl_Canvas_Layout_Part_Type) rp->part->type); 130 return (Efl_Canvas_Layout_Part_Type) rp->part->type;
139} 131}
140 132
141EOLIAN static Eina_Bool 133EOLIAN static Eina_Bool
142_efl_canvas_layout_part_efl_ui_drag_drag_value_set(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy) 134_efl_canvas_layout_part_efl_ui_drag_drag_value_set(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy)
143{ 135{
144 PROXY_CALL_BEGIN(pd); 136 return _edje_object_part_drag_value_set(pd->ed, pd->part, dx, dy);
145 RETURN_VAL(_edje_object_part_drag_value_set(pd->ed, pd->part, dx, dy));
146} 137}
147 138
148EOLIAN static Eina_Bool 139EOLIAN static Eina_Bool
149_efl_canvas_layout_part_efl_ui_drag_drag_value_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy) 140_efl_canvas_layout_part_efl_ui_drag_drag_value_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy)
150{ 141{
151 PROXY_CALL_BEGIN(pd); 142 return _edje_object_part_drag_value_get(pd->ed, pd->part, dx, dy);
152 RETURN_VAL(_edje_object_part_drag_value_get(pd->ed, pd->part, dx, dy));
153} 143}
154 144
155EOLIAN static Eina_Bool 145EOLIAN static Eina_Bool
156_efl_canvas_layout_part_efl_ui_drag_drag_size_set(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dw, double dh) 146_efl_canvas_layout_part_efl_ui_drag_drag_size_set(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dw, double dh)
157{ 147{
158 PROXY_CALL_BEGIN(pd); 148 return _edje_object_part_drag_size_set(pd->ed, pd->part, dw, dh);
159 RETURN_VAL(_edje_object_part_drag_size_set(pd->ed, pd->part, dw, dh));
160} 149}
161 150
162EOLIAN static Eina_Bool 151EOLIAN static Eina_Bool
163_efl_canvas_layout_part_efl_ui_drag_drag_size_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double *dw, double *dh) 152_efl_canvas_layout_part_efl_ui_drag_drag_size_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double *dw, double *dh)
164{ 153{
165 PROXY_CALL_BEGIN(pd); 154 return _edje_object_part_drag_size_get(pd->ed, pd->part, dw, dh);
166 RETURN_VAL(_edje_object_part_drag_size_get(pd->ed, pd->part, dw, dh));
167} 155}
168 156
169EOLIAN static Efl_Ui_Drag_Dir 157EOLIAN static Efl_Ui_Drag_Dir
170_efl_canvas_layout_part_efl_ui_drag_drag_dir_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd) 158_efl_canvas_layout_part_efl_ui_drag_drag_dir_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd)
171{ 159{
172 PROXY_CALL_BEGIN(pd); 160 return _edje_object_part_drag_dir_get(pd->ed, pd->part);
173 RETURN_VAL(_edje_object_part_drag_dir_get(pd->ed, pd->part));
174} 161}
175 162
176EOLIAN static Eina_Bool 163EOLIAN static Eina_Bool
177_efl_canvas_layout_part_efl_ui_drag_drag_step_set(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy) 164_efl_canvas_layout_part_efl_ui_drag_drag_step_set(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy)
178{ 165{
179 PROXY_CALL_BEGIN(pd); 166 return _edje_object_part_drag_step_set(pd->ed, pd->part, dx, dy);
180 RETURN_VAL(_edje_object_part_drag_step_set(pd->ed, pd->part, dx, dy));
181} 167}
182 168
183EOLIAN static Eina_Bool 169EOLIAN static Eina_Bool
184_efl_canvas_layout_part_efl_ui_drag_drag_step_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy) 170_efl_canvas_layout_part_efl_ui_drag_drag_step_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy)
185{ 171{
186 PROXY_CALL_BEGIN(pd); 172 return _edje_object_part_drag_step_get(pd->ed, pd->part, dx, dy);
187 RETURN_VAL(_edje_object_part_drag_step_get(pd->ed, pd->part, dx, dy));
188} 173}
189 174
190EOLIAN static Eina_Bool 175EOLIAN static Eina_Bool
191_efl_canvas_layout_part_efl_ui_drag_drag_step_move(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy) 176_efl_canvas_layout_part_efl_ui_drag_drag_step_move(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy)
192{ 177{
193 PROXY_CALL_BEGIN(pd); 178 return _edje_object_part_drag_step(pd->ed, pd->part, dx, dy);
194 RETURN_VAL(_edje_object_part_drag_step(pd->ed, pd->part, dx, dy));
195} 179}
196 180
197EOLIAN static Eina_Bool 181EOLIAN static Eina_Bool
198_efl_canvas_layout_part_efl_ui_drag_drag_page_set(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy) 182_efl_canvas_layout_part_efl_ui_drag_drag_page_set(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy)
199{ 183{
200 PROXY_CALL_BEGIN(pd); 184 return _edje_object_part_drag_page_set(pd->ed, pd->part, dx, dy);
201 RETURN_VAL(_edje_object_part_drag_page_set(pd->ed, pd->part, dx, dy));
202} 185}
203 186
204EOLIAN static Eina_Bool 187EOLIAN static Eina_Bool
205_efl_canvas_layout_part_efl_ui_drag_drag_page_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy) 188_efl_canvas_layout_part_efl_ui_drag_drag_page_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double *dx, double *dy)
206{ 189{
207 PROXY_CALL_BEGIN(pd); 190 return _edje_object_part_drag_page_get(pd->ed, pd->part, dx, dy);
208 RETURN_VAL(_edje_object_part_drag_page_get(pd->ed, pd->part, dx, dy));
209} 191}
210 192
211EOLIAN static Eina_Bool 193EOLIAN static Eina_Bool
212_efl_canvas_layout_part_efl_ui_drag_drag_page_move(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy) 194_efl_canvas_layout_part_efl_ui_drag_drag_page_move(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, double dx, double dy)
213{ 195{
214 PROXY_CALL_BEGIN(pd); 196 return _edje_object_part_drag_page(pd->ed, pd->part, dx, dy);
215 RETURN_VAL(_edje_object_part_drag_page(pd->ed, pd->part, dx, dy));
216} 197}
217 198
218static Eo * 199static Eo *
219_edje_invalid_part_efl_content_get(Eo *obj, Efl_Canvas_Layout_Part_Data *pd) 200_edje_invalid_part_efl_content_get(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd)
220{ 201{
221 ERR("Part '%s' (type: %s) of group '%s' is not a SWALLOW part!", pd->part, _part_type_to_string(pd->rp->type), pd->ed->group); 202 ERR("Part '%s' (type: %s) of group '%s' is not a SWALLOW part!", pd->part, _part_type_to_string(pd->rp->type), pd->ed->group);
222 RETURN_VAL(NULL); 203 return NULL;
223} 204}
224 205
225static Eina_Bool 206static Eina_Bool
226_edje_invalid_part_efl_content_set(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, Eo *subobj EINA_UNUSED) 207_edje_invalid_part_efl_content_set(Eo *obj EINA_UNUSED, Efl_Canvas_Layout_Part_Data *pd, Eo *subobj EINA_UNUSED)
227{ 208{
228 ERR("Part '%s' (type: %s) of group '%s' is not a SWALLOW part!", pd->part, _part_type_to_string(pd->rp->type), pd->ed->group); 209 ERR("Part '%s' (type: %s) of group '%s' is not a SWALLOW part!", pd->part, _part_type_to_string(pd->rp->type), pd->ed->group);
229 RETURN_VAL(EINA_FALSE); 210 return EINA_FALSE;
230} 211}
231 212
232/* Internal EO APIs and hidden overrides */ 213/* Internal EO APIs and hidden overrides */
diff --git a/src/lib/edje/edje_part_box.c b/src/lib/edje/edje_part_box.c
index 5c6a57a99c..b74457edd8 100644
--- a/src/lib/edje/edje_part_box.c
+++ b/src/lib/edje/edje_part_box.c
@@ -16,14 +16,14 @@ EOLIAN static Eina_Bool
16_efl_canvas_layout_part_box_efl_pack_pack_clear(Eo *obj, void *_pd EINA_UNUSED) 16_efl_canvas_layout_part_box_efl_pack_pack_clear(Eo *obj, void *_pd EINA_UNUSED)
17{ 17{
18 PROXY_DATA_GET(obj, pd); 18 PROXY_DATA_GET(obj, pd);
19 RETURN_VAL(_edje_part_box_remove_all(pd->ed, pd->part, EINA_TRUE)); 19 return _edje_part_box_remove_all(pd->ed, pd->part, EINA_TRUE);
20} 20}
21 21
22EOLIAN static Eina_Bool 22EOLIAN static Eina_Bool
23_efl_canvas_layout_part_box_efl_pack_unpack_all(Eo *obj, void *_pd EINA_UNUSED) 23_efl_canvas_layout_part_box_efl_pack_unpack_all(Eo *obj, void *_pd EINA_UNUSED)
24{ 24{
25 PROXY_DATA_GET(obj, pd); 25 PROXY_DATA_GET(obj, pd);
26 RETURN_VAL(_edje_part_box_remove_all(pd->ed, pd->part, EINA_FALSE)); 26 return _edje_part_box_remove_all(pd->ed, pd->part, EINA_FALSE);
27} 27}
28 28
29EOLIAN static Eina_Bool 29EOLIAN static Eina_Bool
@@ -32,63 +32,63 @@ _efl_canvas_layout_part_box_efl_pack_unpack(Eo *obj, void *_pd EINA_UNUSED, Efl_
32 Evas_Object *removed; 32 Evas_Object *removed;
33 PROXY_DATA_GET(obj, pd); 33 PROXY_DATA_GET(obj, pd);
34 removed = _edje_part_box_remove(pd->ed, pd->part, subobj); 34 removed = _edje_part_box_remove(pd->ed, pd->part, subobj);
35 RETURN_VAL((removed == subobj)); 35 return (removed == subobj);
36} 36}
37 37
38EOLIAN static Eina_Bool 38EOLIAN static Eina_Bool
39_efl_canvas_layout_part_box_efl_pack_pack(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj) 39_efl_canvas_layout_part_box_efl_pack_pack(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj)
40{ 40{
41 PROXY_DATA_GET(obj, pd); 41 PROXY_DATA_GET(obj, pd);
42 RETURN_VAL(_edje_part_box_append(pd->ed, pd->part, subobj)); 42 return _edje_part_box_append(pd->ed, pd->part, subobj);
43} 43}
44 44
45EOLIAN static Eina_Bool 45EOLIAN static Eina_Bool
46_efl_canvas_layout_part_box_efl_pack_linear_pack_begin(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj) 46_efl_canvas_layout_part_box_efl_pack_linear_pack_begin(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj)
47{ 47{
48 PROXY_DATA_GET(obj, pd); 48 PROXY_DATA_GET(obj, pd);
49 RETURN_VAL(_edje_part_box_prepend(pd->ed, pd->part, subobj)); 49 return _edje_part_box_prepend(pd->ed, pd->part, subobj);
50} 50}
51 51
52EOLIAN static Eina_Bool 52EOLIAN static Eina_Bool
53_efl_canvas_layout_part_box_efl_pack_linear_pack_end(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj) 53_efl_canvas_layout_part_box_efl_pack_linear_pack_end(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj)
54{ 54{
55 PROXY_DATA_GET(obj, pd); 55 PROXY_DATA_GET(obj, pd);
56 RETURN_VAL(_edje_part_box_append(pd->ed, pd->part, subobj)); 56 return _edje_part_box_append(pd->ed, pd->part, subobj);
57} 57}
58 58
59EOLIAN static Eina_Bool 59EOLIAN static Eina_Bool
60_efl_canvas_layout_part_box_efl_pack_linear_pack_before(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, const Efl_Gfx *existing) 60_efl_canvas_layout_part_box_efl_pack_linear_pack_before(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, const Efl_Gfx *existing)
61{ 61{
62 PROXY_DATA_GET(obj, pd); 62 PROXY_DATA_GET(obj, pd);
63 RETURN_VAL(_edje_part_box_insert_before(pd->ed, pd->part, subobj, existing)); 63 return _edje_part_box_insert_before(pd->ed, pd->part, subobj, existing);
64} 64}
65 65
66EOLIAN static Eina_Bool 66EOLIAN static Eina_Bool
67_efl_canvas_layout_part_box_efl_pack_linear_pack_after(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, const Efl_Gfx *existing) 67_efl_canvas_layout_part_box_efl_pack_linear_pack_after(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, const Efl_Gfx *existing)
68{ 68{
69 PROXY_DATA_GET(obj, pd); 69 PROXY_DATA_GET(obj, pd);
70 RETURN_VAL(_edje_part_box_insert_after(pd->ed, pd->part, subobj, existing)); 70 return _edje_part_box_insert_after(pd->ed, pd->part, subobj, existing);
71} 71}
72 72
73EOLIAN static Eina_Bool 73EOLIAN static Eina_Bool
74_efl_canvas_layout_part_box_efl_pack_linear_pack_at(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, int index) 74_efl_canvas_layout_part_box_efl_pack_linear_pack_at(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, int index)
75{ 75{
76 PROXY_DATA_GET(obj, pd); 76 PROXY_DATA_GET(obj, pd);
77 int cnt = PROXY_CALL(efl_content_count(obj)); 77 int cnt = efl_content_count(obj);
78 if ((index < 0) && ((-index) <= (cnt + 1))) 78 if ((index < 0) && ((-index) <= (cnt + 1)))
79 index = cnt + index + 1; 79 index = cnt + index + 1;
80 if ((index >= 0) && (index < cnt)) 80 if ((index >= 0) && (index < cnt))
81 RETURN_VAL(_edje_part_box_insert_at(pd->ed, pd->part, subobj, index)); 81 return _edje_part_box_insert_at(pd->ed, pd->part, subobj, index);
82 else 82 else
83 RETURN_VAL(_edje_part_box_append(pd->ed, pd->part, subobj)); 83 return _edje_part_box_append(pd->ed, pd->part, subobj);
84} 84}
85 85
86EOLIAN static Efl_Gfx * 86EOLIAN static Efl_Gfx *
87_efl_canvas_layout_part_box_efl_pack_linear_pack_unpack_at(Eo *obj, void *_pd EINA_UNUSED, int index) 87_efl_canvas_layout_part_box_efl_pack_linear_pack_unpack_at(Eo *obj, void *_pd EINA_UNUSED, int index)
88{ 88{
89 PROXY_DATA_GET(obj, pd); 89 PROXY_DATA_GET(obj, pd);
90 if (index < 0) index += PROXY_CALL(efl_content_count(obj)); 90 if (index < 0) index += efl_content_count(obj);
91 RETURN_VAL(_edje_part_box_remove_at(pd->ed, pd->part, index)); 91 return _edje_part_box_remove_at(pd->ed, pd->part, index);
92} 92}
93 93
94/* New APIs with Eo */ 94/* New APIs with Eo */
@@ -97,15 +97,15 @@ EOLIAN static Efl_Gfx *
97_efl_canvas_layout_part_box_efl_pack_linear_pack_content_get(Eo *obj, void *_pd EINA_UNUSED, int index) 97_efl_canvas_layout_part_box_efl_pack_linear_pack_content_get(Eo *obj, void *_pd EINA_UNUSED, int index)
98{ 98{
99 PROXY_DATA_GET(obj, pd); 99 PROXY_DATA_GET(obj, pd);
100 if (index < 0) index += PROXY_CALL(efl_content_count(obj)); 100 if (index < 0) index += efl_content_count(obj);
101 RETURN_VAL(_edje_part_box_content_at(pd->ed, pd->part, index)); 101 return _edje_part_box_content_at(pd->ed, pd->part, index);
102} 102}
103 103
104EOLIAN static Eina_Bool 104EOLIAN static Eina_Bool
105_efl_canvas_layout_part_box_efl_container_content_remove(Eo *obj, void *_pd EINA_UNUSED EINA_UNUSED, Efl_Gfx *subobj) 105_efl_canvas_layout_part_box_efl_container_content_remove(Eo *obj, void *_pd EINA_UNUSED EINA_UNUSED, Efl_Gfx *subobj)
106{ 106{
107 PROXY_DATA_GET(obj, pd); 107 PROXY_DATA_GET(obj, pd);
108 RETURN_VAL(PROXY_CALL(efl_pack_unpack(obj, subobj))); 108 return efl_pack_unpack(obj, subobj);
109} 109}
110 110
111EOLIAN static int 111EOLIAN static int
@@ -118,14 +118,14 @@ _efl_canvas_layout_part_box_efl_pack_linear_pack_index_get(Eo *obj, void *_pd EI
118 118
119 PROXY_DATA_GET(obj, pd); 119 PROXY_DATA_GET(obj, pd);
120 priv = efl_data_scope_get(pd->rp->object, EVAS_BOX_CLASS); 120 priv = efl_data_scope_get(pd->rp->object, EVAS_BOX_CLASS);
121 if (!priv) RETURN_VAL(-1); 121 if (!priv) return -1;
122 EINA_LIST_FOREACH(priv->children, l, opt) 122 EINA_LIST_FOREACH(priv->children, l, opt)
123 { 123 {
124 if (opt->obj == subobj) 124 if (opt->obj == subobj)
125 RETURN_VAL(k); 125 return k;
126 k++; 126 k++;
127 } 127 }
128 RETURN_VAL(-1); 128 return -1;
129} 129}
130 130
131/* this iterator is the same as efl_ui_box */ 131/* this iterator is the same as efl_ui_box */
@@ -182,17 +182,17 @@ _efl_canvas_layout_part_box_efl_container_content_iterate(Eo *obj, void *_pd EIN
182 Eina_Iterator *it; 182 Eina_Iterator *it;
183 183
184 PROXY_DATA_GET(obj, pd); 184 PROXY_DATA_GET(obj, pd);
185 if (!pd->rp->typedata.container) RETURN_VAL(NULL); 185 if (!pd->rp->typedata.container) return NULL;
186 it = evas_object_box_iterator_new(pd->rp->object); 186 it = evas_object_box_iterator_new(pd->rp->object);
187 187
188 RETURN_VAL(_part_item_iterator_create(pd->rp->object, it)); 188 return _part_item_iterator_create(pd->rp->object, it);
189} 189}
190 190
191EOLIAN static int 191EOLIAN static int
192_efl_canvas_layout_part_box_efl_container_content_count(Eo *obj, void *_pd EINA_UNUSED) 192_efl_canvas_layout_part_box_efl_container_content_count(Eo *obj, void *_pd EINA_UNUSED)
193{ 193{
194 PROXY_DATA_GET(obj, pd); 194 PROXY_DATA_GET(obj, pd);
195 RETURN_VAL(evas_obj_box_count(pd->rp->object)); 195 return evas_obj_box_count(pd->rp->object);
196} 196}
197 197
198EOLIAN static Efl_Ui_Dir 198EOLIAN static Efl_Ui_Dir
@@ -203,15 +203,15 @@ _efl_canvas_layout_part_box_efl_ui_direction_direction_get(Eo *obj, void *_pd EI
203 (Edje_Part_Description_Box *) pd->rp->chosen_description; 203 (Edje_Part_Description_Box *) pd->rp->chosen_description;
204 204
205 if (!desc || !desc->box.layout) 205 if (!desc || !desc->box.layout)
206 RETURN_VAL(EFL_UI_DIR_DEFAULT); 206 return EFL_UI_DIR_DEFAULT;
207 207
208 if (!strncmp(desc->box.layout, "vertical", 8)) 208 if (!strncmp(desc->box.layout, "vertical", 8))
209 RETURN_VAL(EFL_UI_DIR_VERTICAL); 209 return EFL_UI_DIR_VERTICAL;
210 else if (!strncmp(desc->box.layout, "horizontal", 10)) 210 else if (!strncmp(desc->box.layout, "horizontal", 10))
211 RETURN_VAL(EFL_UI_DIR_HORIZONTAL); 211 return EFL_UI_DIR_HORIZONTAL;
212 212
213 WRN("unknown orientation '%s'", desc->box.layout); 213 WRN("unknown orientation '%s'", desc->box.layout);
214 RETURN_VAL(EFL_UI_DIR_DEFAULT); 214 return EFL_UI_DIR_DEFAULT;
215} 215}
216 216
217#include "efl_canvas_layout_part_box.eo.c" 217#include "efl_canvas_layout_part_box.eo.c"
diff --git a/src/lib/edje/edje_part_external.c b/src/lib/edje/edje_part_external.c
index c2f95547fb..ffcaf8036b 100644
--- a/src/lib/edje/edje_part_external.c
+++ b/src/lib/edje/edje_part_external.c
@@ -19,7 +19,7 @@ EOLIAN static Efl_Gfx *
19_efl_canvas_layout_part_external_efl_container_content_get(Eo *obj, void *_pd EINA_UNUSED) 19_efl_canvas_layout_part_external_efl_container_content_get(Eo *obj, void *_pd EINA_UNUSED)
20{ 20{
21 PROXY_DATA_GET(obj, pd); 21 PROXY_DATA_GET(obj, pd);
22 RETURN_VAL(_edje_object_part_external_object_get(pd->ed, pd->part)); 22 return _edje_object_part_external_object_get(pd->ed, pd->part);
23} 23}
24 24
25#include "efl_canvas_layout_part_external.eo.c" 25#include "efl_canvas_layout_part_external.eo.c"
diff --git a/src/lib/edje/edje_part_helper.h b/src/lib/edje/edje_part_helper.h
index 3bea35fc45..c3214c49de 100644
--- a/src/lib/edje/edje_part_helper.h
+++ b/src/lib/edje/edje_part_helper.h
@@ -9,7 +9,6 @@ struct _Efl_Canvas_Layout_Part_Data
9 Edje_Real_Part *rp; 9 Edje_Real_Part *rp;
10 const char *part; 10 const char *part;
11 Eo *obj; 11 Eo *obj;
12 unsigned char temp, in_call, in_use;
13}; 12};
14 13
15struct _Part_Item_Iterator 14struct _Part_Item_Iterator
@@ -23,13 +22,6 @@ struct _Part_Item_Iterator
23void _part_reuse_error(Efl_Canvas_Layout_Part_Data *pd); 22void _part_reuse_error(Efl_Canvas_Layout_Part_Data *pd);
24const char * _part_type_to_string(unsigned char type); 23const char * _part_type_to_string(unsigned char type);
25 24
26#define PROXY_CALL_BEGIN(pd) do { pd->in_call = 1; } while (0)
27#define PROXY_CALL_END(pd) do { pd->in_call = 0; } while (0)
28#define PROXY_REF(obj, pd) do { if (!(pd->temp++)) efl_ref(obj); } while(0)
29#define PROXY_UNREF(obj, pd) do { if (pd->temp) { if (!(--pd->temp)) efl_del(obj); } } while(0)
30#define RETURN_VAL(a) do { typeof(a) _ret = a; PROXY_CALL_END(pd); PROXY_UNREF(obj, pd); return _ret; } while(0)
31#define RETURN_VOID do { PROXY_CALL_END(pd); PROXY_UNREF(obj, pd); return; } while(0)
32#define PROXY_CALL(a) ({ PROXY_REF(obj, pd); a; })
33#define PROXY_STATIC_VAR(type) _##type##_proxy 25#define PROXY_STATIC_VAR(type) _##type##_proxy
34 26
35#ifndef PROXY_ADD_EXTRA_OP 27#ifndef PROXY_ADD_EXTRA_OP
@@ -44,10 +36,6 @@ _part_proxy_del_cb(Eo *proxy, Eo **static_var)
44 Efl_Canvas_Layout_Part_Data *pd; 36 Efl_Canvas_Layout_Part_Data *pd;
45 if (*static_var) 37 if (*static_var)
46 { 38 {
47 // FIXME: Enable debug checks only in debug mode
48 pd = efl_data_scope_get(*static_var, EFL_CANVAS_LAYOUT_PART_CLASS);
49 if (pd && pd->temp && !pd->in_call)
50 _part_reuse_error(pd);
51 if (*static_var != proxy) 39 if (*static_var != proxy)
52 efl_del_intercept_set(*static_var, NULL); 40 efl_del_intercept_set(*static_var, NULL);
53 } 41 }
@@ -58,7 +46,6 @@ _part_proxy_del_cb(Eo *proxy, Eo **static_var)
58 } 46 }
59 efl_reuse(proxy); 47 efl_reuse(proxy);
60 pd = efl_data_scope_get(proxy, EFL_CANVAS_LAYOUT_PART_CLASS); 48 pd = efl_data_scope_get(proxy, EFL_CANVAS_LAYOUT_PART_CLASS);
61 pd->in_use = EINA_FALSE;
62 *static_var = proxy; 49 *static_var = proxy;
63} 50}
64 51
@@ -77,8 +64,7 @@ void \
77_ ## type ## _shutdown(void); \ 64_ ## type ## _shutdown(void); \
78 65
79#define PROXY_DATA_GET(obj, pd) \ 66#define PROXY_DATA_GET(obj, pd) \
80 Efl_Canvas_Layout_Part_Data *pd = efl_data_scope_get(obj, EFL_CANVAS_LAYOUT_PART_CLASS); \ 67 Efl_Canvas_Layout_Part_Data *pd = efl_data_scope_get(obj, EFL_CANVAS_LAYOUT_PART_CLASS);
81 PROXY_CALL_BEGIN(pd)
82 68
83#define PROXY_IMPLEMENTATION(type, KLASS, no_del_cb, ...) \ 69#define PROXY_IMPLEMENTATION(type, KLASS, no_del_cb, ...) \
84static Eo * PROXY_STATIC_VAR(type) = NULL; \ 70static Eo * PROXY_STATIC_VAR(type) = NULL; \
@@ -109,25 +95,15 @@ _edje_ ## type ## _internal_proxy_get(Edje_Object *obj EINA_UNUSED, Edje *ed, Ed
109 proxy = efl_add(KLASS, ed->obj, _edje_real_part_set(efl_added, ed, rp, rp->part->name)); \ 95 proxy = efl_add(KLASS, ed->obj, _edje_real_part_set(efl_added, ed, rp, rp->part->name)); \
110 goto end ; \ 96 goto end ; \
111 } \ 97 } \
98 else PROXY_STATIC_VAR(type) = NULL; \
112 \ 99 \
113 if (EINA_UNLIKELY(pd->in_use)) \ 100 _edje_real_part_set(proxy, ed, rp, rp->part->name); \
114 { \
115 /* if (!pd->in_call) _part_reuse_error(pd); */ \
116 proxy = efl_add(KLASS, ed->obj, _edje_real_part_set(efl_added, ed, rp, rp->part->name)); \
117 } \
118 else \
119 { \
120 _edje_real_part_set(proxy, ed, rp, rp->part->name); \
121 } \
122 \ 101 \
123end: \ 102end: \
124 \
125 __VA_ARGS__; \ 103 __VA_ARGS__; \
126 if (!no_del_cb) \ 104 if (!no_del_cb) efl_del_intercept_set(proxy, _ ## type ## _del_cb); \
127 { \ 105 efl_allow_parent_unref_set(proxy, 1); \
128 PROXY_STATIC_VAR(type) = proxy; \ 106 efl_auto_unref_set(proxy, 1); \
129 efl_del_intercept_set(proxy, _ ## type ## _del_cb); \
130 } \
131 return proxy; \ 107 return proxy; \
132} 108}
133 109
diff --git a/src/lib/edje/edje_part_swallow.c b/src/lib/edje/edje_part_swallow.c
index 6bd2721636..34e637d9b4 100644
--- a/src/lib/edje/edje_part_swallow.c
+++ b/src/lib/edje/edje_part_swallow.c
@@ -11,14 +11,14 @@ EOLIAN static Efl_Gfx *
11_efl_canvas_layout_part_swallow_efl_container_content_get(Eo *obj, void *_pd EINA_UNUSED) 11_efl_canvas_layout_part_swallow_efl_container_content_get(Eo *obj, void *_pd EINA_UNUSED)
12{ 12{
13 PROXY_DATA_GET(obj, pd); 13 PROXY_DATA_GET(obj, pd);
14 RETURN_VAL(_edje_efl_container_content_get(pd->ed, pd->part)); 14 return _edje_efl_container_content_get(pd->ed, pd->part);
15} 15}
16 16
17EOLIAN static Eina_Bool 17EOLIAN static Eina_Bool
18_efl_canvas_layout_part_swallow_efl_container_content_set(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *content) 18_efl_canvas_layout_part_swallow_efl_container_content_set(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *content)
19{ 19{
20 PROXY_DATA_GET(obj, pd); 20 PROXY_DATA_GET(obj, pd);
21 RETURN_VAL(_edje_efl_container_content_set(pd->ed, pd->part, content)); 21 return _edje_efl_container_content_set(pd->ed, pd->part, content);
22} 22}
23 23
24EOLIAN static Efl_Gfx * 24EOLIAN static Efl_Gfx *
@@ -26,9 +26,9 @@ _efl_canvas_layout_part_swallow_efl_container_content_unset(Eo *obj, void *_pd E
26{ 26{
27 PROXY_DATA_GET(obj, pd); 27 PROXY_DATA_GET(obj, pd);
28 Efl_Gfx *content = _edje_efl_container_content_get(pd->ed, pd->part); 28 Efl_Gfx *content = _edje_efl_container_content_get(pd->ed, pd->part);
29 if (!content) RETURN_VAL(NULL); 29 if (!content) return NULL;
30 PROXY_CALL(efl_content_remove(obj, content)); 30 efl_content_remove(obj, content);
31 RETURN_VAL(content); 31 return content;
32} 32}
33 33
34#include "efl_canvas_layout_part_swallow.eo.c" 34#include "efl_canvas_layout_part_swallow.eo.c"
diff --git a/src/lib/edje/edje_part_table.c b/src/lib/edje/edje_part_table.c
index 50c5899546..3fd7c61689 100644
--- a/src/lib/edje/edje_part_table.c
+++ b/src/lib/edje/edje_part_table.c
@@ -64,59 +64,58 @@ _efl_canvas_layout_part_table_efl_container_content_iterate(Eo *obj, void *_pd E
64 Eina_Iterator *it; 64 Eina_Iterator *it;
65 65
66 PROXY_DATA_GET(obj, pd); 66 PROXY_DATA_GET(obj, pd);
67 if (!pd->rp->typedata.container) RETURN_VAL(NULL); 67 if (!pd->rp->typedata.container) return NULL;
68 it = evas_object_table_iterator_new(pd->rp->object); 68 it = evas_object_table_iterator_new(pd->rp->object);
69 69
70 RETURN_VAL(_part_item_iterator_create(pd->rp->object, it)); 70 return _part_item_iterator_create(pd->rp->object, it);
71} 71}
72 72
73EOLIAN static int 73EOLIAN static int
74_efl_canvas_layout_part_table_efl_container_content_count(Eo *obj, void *_pd EINA_UNUSED) 74_efl_canvas_layout_part_table_efl_container_content_count(Eo *obj, void *_pd EINA_UNUSED)
75{ 75{
76 PROXY_DATA_GET(obj, pd); 76 PROXY_DATA_GET(obj, pd);
77 RETURN_VAL(evas_obj_table_count(pd->rp->object)); 77 return evas_obj_table_count(pd->rp->object);
78} 78}
79 79
80EOLIAN static Eina_Bool 80EOLIAN static Eina_Bool
81_efl_canvas_layout_part_table_efl_container_content_remove(Eo *obj, void *_pd EINA_UNUSED EINA_UNUSED, Efl_Gfx *content) 81_efl_canvas_layout_part_table_efl_container_content_remove(Eo *obj EINA_UNUSED, void *_pd EINA_UNUSED EINA_UNUSED, Efl_Gfx *content)
82{ 82{
83 PROXY_DATA_GET(obj, pd); 83 return efl_pack_unpack(obj, content);
84 RETURN_VAL(PROXY_CALL(efl_pack_unpack(obj, content)));
85} 84}
86 85
87EOLIAN static Eina_Bool 86EOLIAN static Eina_Bool
88_efl_canvas_layout_part_table_efl_pack_pack_clear(Eo *obj, void *_pd EINA_UNUSED) 87_efl_canvas_layout_part_table_efl_pack_pack_clear(Eo *obj, void *_pd EINA_UNUSED)
89{ 88{
90 PROXY_DATA_GET(obj, pd); 89 PROXY_DATA_GET(obj, pd);
91 RETURN_VAL(_edje_part_table_clear(pd->ed, pd->part, EINA_TRUE)); 90 return _edje_part_table_clear(pd->ed, pd->part, EINA_TRUE);
92} 91}
93 92
94EOLIAN static Eina_Bool 93EOLIAN static Eina_Bool
95_efl_canvas_layout_part_table_efl_pack_unpack_all(Eo *obj, void *_pd EINA_UNUSED) 94_efl_canvas_layout_part_table_efl_pack_unpack_all(Eo *obj, void *_pd EINA_UNUSED)
96{ 95{
97 PROXY_DATA_GET(obj, pd); 96 PROXY_DATA_GET(obj, pd);
98 RETURN_VAL(_edje_part_table_clear(pd->ed, pd->part, EINA_FALSE)); 97 return _edje_part_table_clear(pd->ed, pd->part, EINA_FALSE);
99} 98}
100 99
101EOLIAN static Eina_Bool 100EOLIAN static Eina_Bool
102_efl_canvas_layout_part_table_efl_pack_unpack(Eo *obj EINA_UNUSED, void *_pd EINA_UNUSED, Efl_Gfx *subobj) 101_efl_canvas_layout_part_table_efl_pack_unpack(Eo *obj EINA_UNUSED, void *_pd EINA_UNUSED, Efl_Gfx *subobj)
103{ 102{
104 PROXY_DATA_GET(obj, pd); 103 PROXY_DATA_GET(obj, pd);
105 RETURN_VAL(_edje_part_table_unpack(pd->ed, pd->part, subobj)); 104 return _edje_part_table_unpack(pd->ed, pd->part, subobj);
106} 105}
107 106
108EOLIAN static Eina_Bool 107EOLIAN static Eina_Bool
109_efl_canvas_layout_part_table_efl_pack_grid_pack_grid(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, int col, int row, int colspan, int rowspan) 108_efl_canvas_layout_part_table_efl_pack_grid_pack_grid(Eo *obj, void *_pd EINA_UNUSED, Efl_Gfx *subobj, int col, int row, int colspan, int rowspan)
110{ 109{
111 PROXY_DATA_GET(obj, pd); 110 PROXY_DATA_GET(obj, pd);
112 RETURN_VAL(_edje_part_table_pack(pd->ed, pd->part, subobj, col, row, colspan, rowspan)); 111 return _edje_part_table_pack(pd->ed, pd->part, subobj, col, row, colspan, rowspan);
113} 112}
114 113
115EOLIAN static Efl_Gfx * 114EOLIAN static Efl_Gfx *
116_efl_canvas_layout_part_table_efl_pack_grid_grid_content_get(Eo *obj, void *_pd EINA_UNUSED, int col, int row) 115_efl_canvas_layout_part_table_efl_pack_grid_grid_content_get(Eo *obj, void *_pd EINA_UNUSED, int col, int row)
117{ 116{
118 PROXY_DATA_GET(obj, pd); 117 PROXY_DATA_GET(obj, pd);
119 RETURN_VAL(_edje_part_table_child_get(pd->ed, pd->part, col, row)); 118 return _edje_part_table_child_get(pd->ed, pd->part, col, row);
120} 119}
121 120
122EOLIAN static void 121EOLIAN static void
@@ -124,7 +123,6 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_size_get(Eo *obj, void *_pd EIN
124{ 123{
125 PROXY_DATA_GET(obj, pd); 124 PROXY_DATA_GET(obj, pd);
126 _edje_part_table_col_row_size_get(pd->ed, pd->part, cols, rows); 125 _edje_part_table_col_row_size_get(pd->ed, pd->part, cols, rows);
127 RETURN_VOID;
128} 126}
129 127
130EOLIAN static int 128EOLIAN static int
@@ -133,7 +131,7 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_columns_get(Eo *obj, void *_pd
133 PROXY_DATA_GET(obj, pd); 131 PROXY_DATA_GET(obj, pd);
134 int cols = 0, rows = 0; 132 int cols = 0, rows = 0;
135 _edje_part_table_col_row_size_get(pd->ed, pd->part, &cols, &rows); 133 _edje_part_table_col_row_size_get(pd->ed, pd->part, &cols, &rows);
136 RETURN_VAL(cols); 134 return cols;
137} 135}
138 136
139EOLIAN static int 137EOLIAN static int
@@ -142,7 +140,7 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_rows_get(Eo *obj, void *_pd EIN
142 PROXY_DATA_GET(obj, pd); 140 PROXY_DATA_GET(obj, pd);
143 int cols = 0, rows = 0; 141 int cols = 0, rows = 0;
144 _edje_part_table_col_row_size_get(pd->ed, pd->part, &cols, &rows); 142 _edje_part_table_col_row_size_get(pd->ed, pd->part, &cols, &rows);
145 RETURN_VAL(rows); 143 return rows;
146} 144}
147 145
148/* New table apis with eo */ 146/* New table apis with eo */
@@ -203,7 +201,7 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_contents_get(Eo *obj, void *_pd
203 eina_iterator_free(it); 201 eina_iterator_free(it);
204 202
205 pit = calloc(1, sizeof(*pit)); 203 pit = calloc(1, sizeof(*pit));
206 if (!pit) RETURN_VAL(NULL); 204 if (!pit) return NULL;
207 205
208 EINA_MAGIC_SET(&pit->iterator, EINA_MAGIC_ITERATOR); 206 EINA_MAGIC_SET(&pit->iterator, EINA_MAGIC_ITERATOR);
209 207
@@ -215,7 +213,7 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_contents_get(Eo *obj, void *_pd
215 pit->iterator.free = FUNC_ITERATOR_FREE(_table_item_iterator_free); 213 pit->iterator.free = FUNC_ITERATOR_FREE(_table_item_iterator_free);
216 efl_wref_add(obj, &pit->object); 214 efl_wref_add(obj, &pit->object);
217 215
218 RETURN_VAL(&pit->iterator); 216 return &pit->iterator;
219} 217}
220 218
221EOLIAN static Eina_Bool 219EOLIAN static Eina_Bool
@@ -231,7 +229,7 @@ _efl_canvas_layout_part_table_efl_pack_grid_grid_position_get(Eo *obj, void *_pd
231 if (colspan) *colspan = cs; 229 if (colspan) *colspan = cs;
232 if (rowspan) *rowspan = rs; 230 if (rowspan) *rowspan = rs;
233 231
234 RETURN_VAL(ret); 232 return ret;
235} 233}
236 234
237/* Legacy API implementation */ 235/* Legacy API implementation */
diff --git a/src/lib/edje/edje_part_text.c b/src/lib/edje/edje_part_text.c
index 56c96ee7e0..f196c2d8a8 100644
--- a/src/lib/edje/edje_part_text.c
+++ b/src/lib/edje/edje_part_text.c
@@ -12,7 +12,6 @@ _efl_canvas_layout_part_text_efl_text_text_set(Eo *obj,
12{ 12{
13 PROXY_DATA_GET(obj, pd); 13 PROXY_DATA_GET(obj, pd);
14 _edje_efl_text_set(obj, pd->ed, pd->part, text, EINA_FALSE, EINA_FALSE); 14 _edje_efl_text_set(obj, pd->ed, pd->part, text, EINA_FALSE, EINA_FALSE);
15 RETURN_VOID;
16} 15}
17 16
18EOLIAN static const char * 17EOLIAN static const char *
@@ -20,7 +19,7 @@ _efl_canvas_layout_part_text_efl_text_text_get(Eo *obj,
20 void *_pd EINA_UNUSED) 19 void *_pd EINA_UNUSED)
21{ 20{
22 PROXY_DATA_GET(obj, pd); 21 PROXY_DATA_GET(obj, pd);
23 RETURN_VAL(_edje_efl_text_get(obj, pd->ed, pd->part, EINA_FALSE, EINA_FALSE)); 22 return _edje_efl_text_get(obj, pd->ed, pd->part, EINA_FALSE, EINA_FALSE);
24} 23}
25 24
26EOLIAN static const char * 25EOLIAN static const char *
@@ -28,7 +27,7 @@ _efl_canvas_layout_part_text_efl_text_markup_markup_get(Eo *obj,
28 void *_pd EINA_UNUSED) 27 void *_pd EINA_UNUSED)
29{ 28{
30 PROXY_DATA_GET(obj, pd); 29 PROXY_DATA_GET(obj, pd);
31 RETURN_VAL(_edje_efl_text_get(obj, pd->ed, pd->part, EINA_FALSE, EINA_TRUE)); 30 return _edje_efl_text_get(obj, pd->ed, pd->part, EINA_FALSE, EINA_TRUE);
32} 31}
33 32
34EOLIAN static void 33EOLIAN static void
@@ -37,7 +36,6 @@ _efl_canvas_layout_part_text_efl_text_markup_markup_set(Eo *obj,
37{ 36{
38 PROXY_DATA_GET(obj, pd); 37 PROXY_DATA_GET(obj, pd);
39 _edje_efl_text_set(obj, pd->ed, pd->part, text, EINA_FALSE, EINA_TRUE); 38 _edje_efl_text_set(obj, pd->ed, pd->part, text, EINA_FALSE, EINA_TRUE);
40 RETURN_VOID;
41} 39}
42 40
43 41
@@ -46,7 +44,7 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_get(Eo *obj,
46 void *_pd EINA_UNUSED, Efl_Text_Cursor_Cursor_Get_Type get_type) 44 void *_pd EINA_UNUSED, Efl_Text_Cursor_Cursor_Get_Type get_type)
47{ 45{
48 PROXY_DATA_GET(obj, pd); 46 PROXY_DATA_GET(obj, pd);
49 RETURN_VAL(_edje_text_cursor_get(pd->rp, (int) get_type)); 47 return _edje_text_cursor_get(pd->rp, (int) get_type);
50} 48}
51 49
52EOLIAN static void 50EOLIAN static void
@@ -55,7 +53,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_paragraph_first(Eo *obj,
55{ 53{
56 PROXY_DATA_GET(obj, pd); 54 PROXY_DATA_GET(obj, pd);
57 _edje_text_cursor_begin(pd->rp, cur); 55 _edje_text_cursor_begin(pd->rp, cur);
58 RETURN_VOID;
59} 56}
60 57
61EOLIAN static void 58EOLIAN static void
@@ -64,7 +61,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_paragraph_last(Eo *obj,
64{ 61{
65 PROXY_DATA_GET(obj, pd); 62 PROXY_DATA_GET(obj, pd);
66 _edje_text_cursor_end(pd->rp, cur); 63 _edje_text_cursor_end(pd->rp, cur);
67 RETURN_VOID;
68} 64}
69 65
70EOLIAN static void 66EOLIAN static void
@@ -73,7 +69,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_position_set(Eo *obj,
73{ 69{
74 PROXY_DATA_GET(obj, pd); 70 PROXY_DATA_GET(obj, pd);
75 _edje_text_cursor_pos_set(pd->rp, cur, pos); 71 _edje_text_cursor_pos_set(pd->rp, cur, pos);
76 RETURN_VOID;
77} 72}
78 73
79EOLIAN static int 74EOLIAN static int
@@ -81,7 +76,7 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_position_get(Eo *obj,
81 void *_pd EINA_UNUSED, Efl_Text_Cursor_Cursor *cur) 76 void *_pd EINA_UNUSED, Efl_Text_Cursor_Cursor *cur)
82{ 77{
83 PROXY_DATA_GET(obj, pd); 78 PROXY_DATA_GET(obj, pd);
84 RETURN_VAL(_edje_text_cursor_pos_get(pd->rp, cur)); 79 return _edje_text_cursor_pos_get(pd->rp, cur);
85} 80}
86 81
87EOLIAN static void 82EOLIAN static void
@@ -91,7 +86,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_coord_set(Eo *obj,
91{ 86{
92 PROXY_DATA_GET(obj, pd); 87 PROXY_DATA_GET(obj, pd);
93 _edje_text_cursor_coord_set(pd->rp, cur, x, y); 88 _edje_text_cursor_coord_set(pd->rp, cur, x, y);
94 RETURN_VOID;
95} 89}
96 90
97EOLIAN static void 91EOLIAN static void
@@ -100,7 +94,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_line_char_first(Eo *obj,
100{ 94{
101 PROXY_DATA_GET(obj, pd); 95 PROXY_DATA_GET(obj, pd);
102 _edje_text_cursor_line_begin(pd->rp, cur); 96 _edje_text_cursor_line_begin(pd->rp, cur);
103 RETURN_VOID;
104} 97}
105 98
106EOLIAN static void 99EOLIAN static void
@@ -109,7 +102,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_line_char_last(Eo *obj,
109{ 102{
110 PROXY_DATA_GET(obj, pd); 103 PROXY_DATA_GET(obj, pd);
111 _edje_text_cursor_line_end(pd->rp, cur); 104 _edje_text_cursor_line_end(pd->rp, cur);
112 RETURN_VOID;
113} 105}
114 106
115EOLIAN static void 107EOLIAN static void
@@ -118,7 +110,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_char_prev(Eo *obj,
118{ 110{
119 PROXY_DATA_GET(obj, pd); 111 PROXY_DATA_GET(obj, pd);
120 _edje_text_cursor_prev(pd->rp, cur); 112 _edje_text_cursor_prev(pd->rp, cur);
121 RETURN_VOID;
122} 113}
123 114
124EOLIAN static void 115EOLIAN static void
@@ -127,7 +118,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_char_next(Eo *obj,
127{ 118{
128 PROXY_DATA_GET(obj, pd); 119 PROXY_DATA_GET(obj, pd);
129 _edje_text_cursor_next(pd->rp, cur); 120 _edje_text_cursor_next(pd->rp, cur);
130 RETURN_VOID;
131} 121}
132 122
133EOLIAN static void 123EOLIAN static void
@@ -143,7 +133,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_line_jump_by(Eo *obj,
143 { 133 {
144 _edje_text_cursor_up(pd->rp, cur); 134 _edje_text_cursor_up(pd->rp, cur);
145 } 135 }
146 RETURN_VOID;
147} 136}
148 137
149EOLIAN static void 138EOLIAN static void
@@ -154,7 +143,6 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_copy(Eo *obj,
154{ 143{
155 PROXY_DATA_GET(obj, pd); 144 PROXY_DATA_GET(obj, pd);
156 _edje_text_cursor_copy(pd->rp, (Efl_Text_Cursor_Cursor *) cur, dst); 145 _edje_text_cursor_copy(pd->rp, (Efl_Text_Cursor_Cursor *) cur, dst);
157 RETURN_VOID;
158} 146}
159 147
160EOLIAN static Eina_Unicode 148EOLIAN static Eina_Unicode
@@ -176,7 +164,7 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_content_get(Eo *obj,
176 uc = *ustr; 164 uc = *ustr;
177 free(ustr); 165 free(ustr);
178 } 166 }
179 RETURN_VAL(uc); 167 return uc;
180} 168}
181 169
182EOLIAN static Eina_Bool 170EOLIAN static Eina_Bool
@@ -195,7 +183,7 @@ _efl_canvas_layout_part_text_efl_text_cursor_cursor_geometry_get(Eo *obj,
195 if (cx) *cx -= pd->ed->x; 183 if (cx) *cx -= pd->ed->x;
196 if (cy) *cy -= pd->ed->y; 184 if (cy) *cy -= pd->ed->y;
197 } 185 }
198 RETURN_VAL(EINA_FALSE); 186 return EINA_FALSE;
199} 187}
200 188
201EOLIAN static void 189EOLIAN static void
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index 90e248922d..2096362a89 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -39,6 +39,9 @@
39# include <Evil.h> 39# include <Evil.h>
40#endif 40#endif
41 41
42// auto_unref
43#define EFL_OBJECT_BETA
44#define EFL_OBJECT_PROTECTED
42#define EDJE_OBJECT_BETA 45#define EDJE_OBJECT_BETA
43#define EFL_CANVAS_OBJECT_PROTECTED 46#define EFL_CANVAS_OBJECT_PROTECTED
44#define EFL_CANVAS_LAYOUT_CALC_PROTECTED 47#define EFL_CANVAS_LAYOUT_CALC_PROTECTED