summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2016-06-09 17:30:05 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2016-06-10 13:21:20 +0900
commit79abba52c50840c043e4bb4dced6b533f9cdaebd (patch)
treec49c2686fd718ccfcd3cb022a49440bc206ae09f
parent3bee4995033d220117f4f31493470e4d0db1487a (diff)
Evas: Rename Evas.Image into Efl.Canvas.Image.Internal
Make it abstract. And add Evas.Image as a legacy-only class.
-rw-r--r--src/Makefile_Evas.am3
-rw-r--r--src/examples/evas/evas-object-manipulation-eo.c4
-rw-r--r--src/lib/edje/edje_calc.c2
-rw-r--r--src/lib/edje/edje_util.c4
-rw-r--r--src/lib/elementary/efl_ui_flip.c2
-rw-r--r--src/lib/evas/Evas_Eo.h2
-rw-r--r--src/lib/evas/canvas/efl_canvas_image.c62
-rw-r--r--src/lib/evas/canvas/efl_canvas_image_internal.eo45
-rw-r--r--src/lib/evas/canvas/efl_canvas_proxy.c24
-rw-r--r--src/lib/evas/canvas/efl_canvas_scene3d.c8
-rw-r--r--src/lib/evas/canvas/evas_canvas3d_texture.c2
-rw-r--r--src/lib/evas/canvas/evas_image.eo48
-rw-r--r--src/lib/evas/canvas/evas_image_legacy.c80
-rw-r--r--src/lib/evas/canvas/evas_main.c4
-rw-r--r--src/lib/evas/canvas/evas_object_image.c125
-rw-r--r--src/lib/evas/canvas/evas_object_main.c4
-rw-r--r--src/lib/evas/canvas/evas_render.c4
-rw-r--r--src/tests/evas/evas_test_image.c2
18 files changed, 216 insertions, 209 deletions
diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index bf3208f94f..4a2aeddde4 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -10,7 +10,7 @@ evas_eolian_pub_files = \
10 lib/evas/canvas/evas_object_smart.eo \ 10 lib/evas/canvas/evas_object_smart.eo \
11 lib/evas/canvas/evas_common_interface.eo \ 11 lib/evas/canvas/evas_common_interface.eo \
12 lib/evas/canvas/evas_canvas.eo \ 12 lib/evas/canvas/evas_canvas.eo \
13 lib/evas/canvas/evas_image.eo \ 13 lib/evas/canvas/efl_canvas_image_internal.eo \
14 lib/evas/canvas/evas_draggable_interface.eo \ 14 lib/evas/canvas/evas_draggable_interface.eo \
15 lib/evas/canvas/evas_clickable_interface.eo \ 15 lib/evas/canvas/evas_clickable_interface.eo \
16 lib/evas/canvas/evas_scrollable_interface.eo \ 16 lib/evas/canvas/evas_scrollable_interface.eo \
@@ -56,6 +56,7 @@ evas_eolian_legacy_files = \
56 lib/evas/canvas/evas_out.eo \ 56 lib/evas/canvas/evas_out.eo \
57 lib/evas/canvas/evas_text.eo \ 57 lib/evas/canvas/evas_text.eo \
58 lib/evas/canvas/evas_textgrid.eo \ 58 lib/evas/canvas/evas_textgrid.eo \
59 lib/evas/canvas/evas_image.eo \
59 $(NULL) 60 $(NULL)
60 61
61evas_eolian_priv_files = \ 62evas_eolian_priv_files = \
diff --git a/src/examples/evas/evas-object-manipulation-eo.c b/src/examples/evas/evas-object-manipulation-eo.c
index f0d3efa624..f32de7b815 100644
--- a/src/examples/evas/evas-object-manipulation-eo.c
+++ b/src/examples/evas/evas-object-manipulation-eo.c
@@ -190,7 +190,7 @@ main(void)
190 evas_object_event_callback_add( 190 evas_object_event_callback_add(
191 d.bg, EVAS_CALLBACK_KEY_DOWN, _on_keydown, NULL); 191 d.bg, EVAS_CALLBACK_KEY_DOWN, _on_keydown, NULL);
192 192
193 d.img = eo_add(EVAS_IMAGE_CLASS, d.canvas); 193 d.img = eo_add(EFL_CANVAS_IMAGE_CLASS, d.canvas);
194 194
195 /* As soon as 'canvas' object is a parent for 'image' object, 195 /* As soon as 'canvas' object is a parent for 'image' object,
196 * 'canvas' keeps reference to 'image'. 196 * 'canvas' keeps reference to 'image'.
@@ -216,7 +216,7 @@ main(void)
216 } 216 }
217 217
218 /* border on the image's clipper, here just to emphasize its position */ 218 /* border on the image's clipper, here just to emphasize its position */
219 d.clipper_border = eo_add(EVAS_IMAGE_CLASS, d.canvas); 219 d.clipper_border = eo_add(EFL_CANVAS_IMAGE_CLASS, d.canvas);
220 efl_file_set(d.clipper_border, border_img_path, NULL); 220 efl_file_set(d.clipper_border, border_img_path, NULL);
221 err = efl_image_load_error_get(d.clipper_border); 221 err = efl_image_load_error_get(d.clipper_border);
222 222
diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index eab4f77ed9..add1e756fd 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -3656,7 +3656,7 @@ _edje_map_prop_set(Evas_Map *map, const Edje_Calc_Params *pf,
3656 3656
3657 if (ep->part->type == EDJE_PART_TYPE_IMAGE || 3657 if (ep->part->type == EDJE_PART_TYPE_IMAGE ||
3658 ((ep->part->type == EDJE_PART_TYPE_SWALLOW) && 3658 ((ep->part->type == EDJE_PART_TYPE_SWALLOW) &&
3659 (eo_isa(mo, EVAS_IMAGE_CLASS) && 3659 (eo_isa(mo, EFL_CANVAS_IMAGE_INTERNAL_CLASS) &&
3660 (!evas_object_image_source_get(mo)))) 3660 (!evas_object_image_source_get(mo))))
3661 ) 3661 )
3662 { 3662 {
diff --git a/src/lib/edje/edje_util.c b/src/lib/edje/edje_util.c
index 40b4717261..91be7b57e3 100644
--- a/src/lib/edje/edje_util.c
+++ b/src/lib/edje/edje_util.c
@@ -6490,7 +6490,7 @@ _edje_real_part_swallow(Edje *ed,
6490 evas_object_data_set(rp->typedata.swallow->swallowed_object, ".edje", ed); 6490 evas_object_data_set(rp->typedata.swallow->swallowed_object, ".edje", ed);
6491 6491
6492 //If the map is enabled, uv should be updated when image size is changed. 6492 //If the map is enabled, uv should be updated when image size is changed.
6493 if (eo_isa(rp->typedata.swallow->swallowed_object, EVAS_IMAGE_CLASS)) 6493 if (eo_isa(rp->typedata.swallow->swallowed_object, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
6494 evas_object_event_callback_add(obj_swallow, EVAS_CALLBACK_IMAGE_RESIZE, 6494 evas_object_event_callback_add(obj_swallow, EVAS_CALLBACK_IMAGE_RESIZE,
6495 _edje_object_part_swallow_image_resize_cb, 6495 _edje_object_part_swallow_image_resize_cb,
6496 rp); 6496 rp);
@@ -6535,7 +6535,7 @@ _edje_real_part_swallow_clear(Edje *ed, Edje_Real_Part *rp)
6535 EVAS_CALLBACK_CHANGED_SIZE_HINTS, 6535 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
6536 _edje_object_part_swallow_changed_hints_cb, 6536 _edje_object_part_swallow_changed_hints_cb,
6537 rp); 6537 rp);
6538 if (eo_isa(rp->typedata.swallow->swallowed_object, EVAS_IMAGE_CLASS)) 6538 if (eo_isa(rp->typedata.swallow->swallowed_object, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
6539 evas_object_event_callback_del_full(rp->typedata.swallow->swallowed_object, 6539 evas_object_event_callback_del_full(rp->typedata.swallow->swallowed_object,
6540 EVAS_CALLBACK_IMAGE_RESIZE, 6540 EVAS_CALLBACK_IMAGE_RESIZE,
6541 _edje_object_part_swallow_image_resize_cb, 6541 _edje_object_part_swallow_image_resize_cb,
diff --git a/src/lib/elementary/efl_ui_flip.c b/src/lib/elementary/efl_ui_flip.c
index a6ac9b50c3..3b7f8c4ce0 100644
--- a/src/lib/elementary/efl_ui_flip.c
+++ b/src/lib/elementary/efl_ui_flip.c
@@ -940,7 +940,7 @@ _map_uv_set(Evas_Object *obj, Evas_Map *map)
940 Evas_Coord x, y, w, h; 940 Evas_Coord x, y, w, h;
941 941
942 // FIXME: only handles filled obj 942 // FIXME: only handles filled obj
943 if (eo_isa(obj, EVAS_IMAGE_CLASS) && 943 if (eo_isa(obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS) &&
944 !evas_object_image_source_get(obj)) 944 !evas_object_image_source_get(obj))
945 { 945 {
946 int iw, ih; 946 int iw, ih;
diff --git a/src/lib/evas/Evas_Eo.h b/src/lib/evas/Evas_Eo.h
index 30cd0d2f45..9f832d5b79 100644
--- a/src/lib/evas/Evas_Eo.h
+++ b/src/lib/evas/Evas_Eo.h
@@ -277,7 +277,7 @@ typedef void (Evas_Canvas3D_Surface_Func)(Evas_Real *out_x,
277 277
278#include "canvas/evas_canvas3d_scene.eo.h" 278#include "canvas/evas_canvas3d_scene.eo.h"
279 279
280#include "canvas/evas_image.eo.h" 280#include "canvas/efl_canvas_image_internal.eo.h"
281#include "canvas/efl_canvas_image.eo.h" 281#include "canvas/efl_canvas_image.eo.h"
282#include "canvas/efl_canvas_snapshot.eo.h" 282#include "canvas/efl_canvas_snapshot.eo.h"
283#include "canvas/efl_canvas_proxy.eo.h" 283#include "canvas/efl_canvas_proxy.eo.h"
diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c
index e799773df4..fb4c1dc321 100644
--- a/src/lib/evas/canvas/efl_canvas_image.c
+++ b/src/lib/evas/canvas/efl_canvas_image.c
@@ -7,7 +7,7 @@ Eina_Bool
7_evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) 7_evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key)
8{ 8{
9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
11 Evas_Image_Load_Opts lo; 11 Evas_Image_Load_Opts lo;
12 12
13 if (o->cur->u.f == f) 13 if (o->cur->u.f == f)
@@ -36,7 +36,7 @@ _efl_canvas_image_efl_file_mmap_set(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSE
36void 36void
37_evas_image_mmap_get(const Eo *eo_obj, const Eina_File **f, const char **key) 37_evas_image_mmap_get(const Eo *eo_obj, const Eina_File **f, const char **key)
38{ 38{
39 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 39 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
40 40
41 if (f) 41 if (f)
42 *f = o->cur->mmaped_source ? o->cur->u.f : NULL; 42 *f = o->cur->mmaped_source ? o->cur->u.f : NULL;
@@ -55,7 +55,7 @@ Eina_Bool
55_evas_image_file_set(Eo *eo_obj, const char *file, const char *key) 55_evas_image_file_set(Eo *eo_obj, const char *file, const char *key)
56{ 56{
57 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 57 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
58 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 58 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
59 Evas_Image_Load_Opts lo; 59 Evas_Image_Load_Opts lo;
60 const char *file2; 60 const char *file2;
61 61
@@ -95,7 +95,7 @@ _efl_canvas_image_efl_file_file_set(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSE
95void 95void
96_evas_image_file_get(const Eo *eo_obj, const char **file, const char **key) 96_evas_image_file_get(const Eo *eo_obj, const char **file, const char **key)
97{ 97{
98 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 98 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
99 99
100 if (file) 100 if (file)
101 { 101 {
@@ -117,7 +117,7 @@ _efl_canvas_image_efl_file_file_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSE
117Efl_Image_Load_Error 117Efl_Image_Load_Error
118_evas_image_load_error_get(const Eo *eo_obj) 118_evas_image_load_error_get(const Eo *eo_obj)
119{ 119{
120 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 120 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
121 121
122 return (Efl_Image_Load_Error) o->load_error; 122 return (Efl_Image_Load_Error) o->load_error;
123} 123}
@@ -162,7 +162,7 @@ void
162_evas_image_load_async_start(Eo *eo_obj) 162_evas_image_load_async_start(Eo *eo_obj)
163{ 163{
164 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 164 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
165 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 165 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
166 166
167 evas_object_async_block(obj); 167 evas_object_async_block(obj);
168 _image_preload_internal(eo_obj, o, EINA_FALSE); 168 _image_preload_internal(eo_obj, o, EINA_FALSE);
@@ -178,7 +178,7 @@ void
178_evas_image_load_async_cancel(Eo *eo_obj) 178_evas_image_load_async_cancel(Eo *eo_obj)
179{ 179{
180 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 180 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
181 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 181 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
182 182
183 evas_object_async_block(obj); 183 evas_object_async_block(obj);
184 _image_preload_internal(eo_obj, o, EINA_TRUE); 184 _image_preload_internal(eo_obj, o, EINA_TRUE);
@@ -194,7 +194,7 @@ void
194_evas_image_load_dpi_set(Eo *eo_obj, double dpi) 194_evas_image_load_dpi_set(Eo *eo_obj, double dpi)
195{ 195{
196 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 196 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
197 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 197 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
198 198
199 if (dpi == o->load_opts->dpi) return; 199 if (dpi == o->load_opts->dpi) return;
200 evas_object_async_block(obj); 200 evas_object_async_block(obj);
@@ -221,7 +221,7 @@ _efl_canvas_image_efl_image_load_load_dpi_set(Eo *eo_obj, void *_pd EINA_UNUSED
221double 221double
222_evas_image_load_dpi_get(const Eo *eo_obj) 222_evas_image_load_dpi_get(const Eo *eo_obj)
223{ 223{
224 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 224 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
225 225
226 return o->load_opts->dpi; 226 return o->load_opts->dpi;
227} 227}
@@ -236,7 +236,7 @@ void
236_evas_image_load_size_set(Eo *eo_obj, int w, int h) 236_evas_image_load_size_set(Eo *eo_obj, int w, int h)
237{ 237{
238 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 238 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
239 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 239 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
240 240
241 if ((o->load_opts->w == w) && (o->load_opts->h == h)) return; 241 if ((o->load_opts->w == w) && (o->load_opts->h == h)) return;
242 evas_object_async_block(obj); 242 evas_object_async_block(obj);
@@ -267,7 +267,7 @@ _efl_canvas_image_efl_image_load_load_size_set(Eo *eo_obj, void *_pd EINA_UNUSED
267void 267void
268_evas_image_load_size_get(const Eo *eo_obj, int *w, int *h) 268_evas_image_load_size_get(const Eo *eo_obj, int *w, int *h)
269{ 269{
270 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 270 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
271 271
272 if (w) *w = o->load_opts->w; 272 if (w) *w = o->load_opts->w;
273 if (h) *h = o->load_opts->h; 273 if (h) *h = o->load_opts->h;
@@ -283,7 +283,7 @@ void
283_evas_image_load_scale_down_set(Eo *eo_obj, int scale_down) 283_evas_image_load_scale_down_set(Eo *eo_obj, int scale_down)
284{ 284{
285 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 285 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
286 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 286 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
287 287
288 if (o->load_opts->scale_down_by == scale_down) return; 288 if (o->load_opts->scale_down_by == scale_down) return;
289 evas_object_async_block(obj); 289 evas_object_async_block(obj);
@@ -310,7 +310,7 @@ _efl_canvas_image_efl_image_load_load_scale_down_set(Eo *eo_obj, void *_pd EINA_
310int 310int
311_evas_image_load_scale_down_get(const Eo *eo_obj) 311_evas_image_load_scale_down_get(const Eo *eo_obj)
312{ 312{
313 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 313 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
314 314
315 return o->load_opts->scale_down_by; 315 return o->load_opts->scale_down_by;
316} 316}
@@ -325,7 +325,7 @@ void
325_evas_image_load_region_set(Eo *eo_obj, int x, int y, int w, int h) 325_evas_image_load_region_set(Eo *eo_obj, int x, int y, int w, int h)
326{ 326{
327 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 327 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
328 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 328 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
329 329
330 if ((o->load_opts->region.x == x) && (o->load_opts->region.y == y) && 330 if ((o->load_opts->region.x == x) && (o->load_opts->region.y == y) &&
331 (o->load_opts->region.w == w) && (o->load_opts->region.h == h)) return; 331 (o->load_opts->region.w == w) && (o->load_opts->region.h == h)) return;
@@ -358,7 +358,7 @@ _efl_canvas_image_efl_image_load_load_region_set(Eo *eo_obj, void *_pd EINA_UNUS
358void 358void
359_evas_image_load_region_get(const Eo *eo_obj, int *x, int *y, int *w, int *h) 359_evas_image_load_region_get(const Eo *eo_obj, int *x, int *y, int *w, int *h)
360{ 360{
361 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 361 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
362 362
363 if (x) *x = o->load_opts->region.x; 363 if (x) *x = o->load_opts->region.x;
364 if (y) *y = o->load_opts->region.y; 364 if (y) *y = o->load_opts->region.y;
@@ -376,7 +376,7 @@ void
376_evas_image_load_orientation_set(Eo *eo_obj, Eina_Bool enable) 376_evas_image_load_orientation_set(Eo *eo_obj, Eina_Bool enable)
377{ 377{
378 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 378 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
379 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 379 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
380 380
381 if (o->load_opts->orientation == !!enable) return; 381 if (o->load_opts->orientation == !!enable) return;
382 evas_object_async_block(obj); 382 evas_object_async_block(obj);
@@ -395,7 +395,7 @@ _efl_canvas_image_efl_image_load_load_orientation_set(Eo *eo_obj, void *_pd EINA
395Eina_Bool 395Eina_Bool
396_evas_image_load_orientation_get(const Eo *eo_obj) 396_evas_image_load_orientation_get(const Eo *eo_obj)
397{ 397{
398 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 398 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
399 399
400 return o->load_opts->orientation; 400 return o->load_opts->orientation;
401} 401}
@@ -410,7 +410,7 @@ Eina_Bool
410_evas_image_load_region_support_get(const Eo *eo_obj) 410_evas_image_load_region_support_get(const Eo *eo_obj)
411{ 411{
412 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 412 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
413 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 413 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
414 414
415 return ENFN->image_can_region_get(ENDT, o->engine_data); 415 return ENFN->image_can_region_get(ENDT, o->engine_data);
416} 416}
@@ -426,7 +426,7 @@ Eina_Bool
426_evas_image_animated_get(const Eo *eo_obj) 426_evas_image_animated_get(const Eo *eo_obj)
427{ 427{
428 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 428 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
429 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 429 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
430 430
431 if (!ENFN->image_animated_get) 431 if (!ENFN->image_animated_get)
432 return EINA_FALSE; 432 return EINA_FALSE;
@@ -444,7 +444,7 @@ int
444_evas_image_animated_frame_count_get(const Eo *eo_obj) 444_evas_image_animated_frame_count_get(const Eo *eo_obj)
445{ 445{
446 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 446 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
447 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 447 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
448 448
449 if (!ENFN->image_animated_frame_count_get || 449 if (!ENFN->image_animated_frame_count_get ||
450 !evas_object_image_animated_get(eo_obj)) 450 !evas_object_image_animated_get(eo_obj))
@@ -464,7 +464,7 @@ Efl_Image_Animated_Loop_Hint
464_evas_image_animated_loop_type_get(const Eo *eo_obj) 464_evas_image_animated_loop_type_get(const Eo *eo_obj)
465{ 465{
466 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 466 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
467 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 467 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
468 468
469 if (!ENFN->image_animated_loop_type_get || 469 if (!ENFN->image_animated_loop_type_get ||
470 !evas_object_image_animated_get(eo_obj)) 470 !evas_object_image_animated_get(eo_obj))
@@ -483,7 +483,7 @@ int
483_evas_image_animated_loop_count_get(const Eo *eo_obj) 483_evas_image_animated_loop_count_get(const Eo *eo_obj)
484{ 484{
485 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 485 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
486 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 486 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
487 487
488 if (!ENFN->image_animated_loop_count_get || 488 if (!ENFN->image_animated_loop_count_get ||
489 !evas_object_image_animated_get(eo_obj)) 489 !evas_object_image_animated_get(eo_obj))
@@ -502,7 +502,7 @@ double
502_evas_image_animated_frame_duration_get(const Eo *eo_obj, int start_frame, int frame_num) 502_evas_image_animated_frame_duration_get(const Eo *eo_obj, int start_frame, int frame_num)
503{ 503{
504 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 504 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
505 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 505 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
506 int frame_count = 0; 506 int frame_count = 0;
507 507
508 if (!ENFN->image_animated_frame_count_get || 508 if (!ENFN->image_animated_frame_count_get ||
@@ -526,7 +526,7 @@ Eina_Bool
526_evas_image_animated_frame_set(Eo *eo_obj, int frame_index) 526_evas_image_animated_frame_set(Eo *eo_obj, int frame_index)
527{ 527{
528 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 528 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
529 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 529 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
530 int frame_count = 0; 530 int frame_count = 0;
531 531
532 if (!o->cur->u.file) return EINA_FALSE; 532 if (!o->cur->u.file) return EINA_FALSE;
@@ -567,7 +567,7 @@ _efl_canvas_image_efl_image_animated_animated_frame_set(Eo *eo_obj, void *_pd EI
567int 567int
568_evas_image_animated_frame_get(const Eo *eo_obj) 568_evas_image_animated_frame_get(const Eo *eo_obj)
569{ 569{
570 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 570 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
571 571
572 if (!o->cur->u.file) return EINA_FALSE; 572 if (!o->cur->u.file) return EINA_FALSE;
573 if (!evas_object_image_animated_get(eo_obj)) return EINA_FALSE; 573 if (!evas_object_image_animated_get(eo_obj)) return EINA_FALSE;
@@ -583,7 +583,7 @@ _efl_canvas_image_efl_image_animated_animated_frame_get(Eo *eo_obj, void *_pd EI
583EOLIAN static void 583EOLIAN static void
584_efl_canvas_image_efl_gfx_buffer_buffer_size_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED, int *w, int *h) 584_efl_canvas_image_efl_gfx_buffer_buffer_size_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED, int *w, int *h)
585{ 585{
586 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 586 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
587 587
588 if (w) *w = o->cur->image.w; 588 if (w) *w = o->cur->image.w;
589 if (h) *h = o->cur->image.h; 589 if (h) *h = o->cur->image.h;
@@ -743,7 +743,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_data_set(Eo *eo_obj, void *_pd EINA_UNUS
743 Efl_Gfx_Colorspace cspace) 743 Efl_Gfx_Colorspace cspace)
744{ 744{
745 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 745 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
746 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 746 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
747 747
748 return _image_pixels_set(obj, o, pixels, w, h, stride, cspace, EINA_FALSE); 748 return _image_pixels_set(obj, o, pixels, w, h, stride, cspace, EINA_FALSE);
749} 749}
@@ -754,7 +754,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_copy_set(Eo *eo_obj, void *_pd EINA_UNUS
754 Efl_Gfx_Colorspace cspace) 754 Efl_Gfx_Colorspace cspace)
755{ 755{
756 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 756 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
757 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 757 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
758 758
759 return _image_pixels_set(obj, o, (void *) pixels, w, h, stride, cspace, EINA_TRUE); 759 return _image_pixels_set(obj, o, (void *) pixels, w, h, stride, cspace, EINA_TRUE);
760} 760}
@@ -763,7 +763,7 @@ EOLIAN static void *
763_efl_canvas_image_efl_gfx_buffer_buffer_data_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED) 763_efl_canvas_image_efl_gfx_buffer_buffer_data_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED)
764{ 764{
765 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 765 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
766 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 766 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
767 767
768 if (!o->buffer_data_set || !o->engine_data || !ENFN->image_data_direct) 768 if (!o->buffer_data_set || !o->engine_data || !ENFN->image_data_direct)
769 return NULL; 769 return NULL;
@@ -779,7 +779,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_map(Eo *eo_obj, void *_pd EINA_UNUSED,
779 Efl_Gfx_Colorspace cspace, int *stride) 779 Efl_Gfx_Colorspace cspace, int *stride)
780{ 780{
781 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 781 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
782 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 782 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
783 int len = 0, s = 0, width = 0, height = 0; 783 int len = 0, s = 0, width = 0, height = 0;
784 void *data = NULL; 784 void *data = NULL;
785 785
@@ -821,7 +821,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_unmap(Eo *eo_obj, void *_pd EINA_UNUSED,
821 void *data, int length) 821 void *data, int length)
822{ 822{
823 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 823 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
824 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 824 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
825 825
826 if (!ENFN->image_data_unmap || !o->engine_data) 826 if (!ENFN->image_data_unmap || !o->engine_data)
827 return EINA_FALSE; 827 return EINA_FALSE;
diff --git a/src/lib/evas/canvas/efl_canvas_image_internal.eo b/src/lib/evas/canvas/efl_canvas_image_internal.eo
new file mode 100644
index 0000000000..211e9bb584
--- /dev/null
+++ b/src/lib/evas/canvas/efl_canvas_image_internal.eo
@@ -0,0 +1,45 @@
1abstract Efl.Canvas.Image.Internal (Evas.Object, Evas.Filter,
2 Efl.Image, Efl.Gfx.Buffer,
3 Efl.Gfx.Fill, Efl.Gfx.View,
4 Efl.Orientation, Efl.Flipable,
5 Efl.File)
6{
7 data: Evas_Image_Data;
8 implements {
9 Eo.Base.constructor;
10 Eo.Base.destructor;
11 Eo.Base.dbg_info_get;
12 Eo.Base.finalize;
13 Efl.File.save;
14 Efl.Orientation.orientation.get;
15 Efl.Orientation.orientation.set;
16 Efl.Flipable.flip.set;
17 Efl.Flipable.flip.get;
18 Efl.Image.smooth_scale.set;
19 Efl.Image.smooth_scale.get;
20 Efl.Image.ratio.get;
21 Efl.Image.border.get;
22 Efl.Image.border.set;
23 Efl.Image.border_scale.get;
24 Efl.Image.border_scale.set;
25 Efl.Image.border_center_fill.get;
26 Efl.Image.border_center_fill.set;
27 Efl.Image.scale_hint.get;
28 Efl.Image.scale_hint.set;
29 Efl.Image.content_hint.get;
30 Efl.Image.content_hint.set;
31 Efl.Gfx.Buffer.alpha.get;
32 Efl.Gfx.Buffer.alpha.set;
33 Efl.Gfx.Buffer.buffer_update_add;
34 Efl.Gfx.Buffer.colorspace.get;
35 Efl.Gfx.Fill.fill.set;
36 Efl.Gfx.Fill.fill.get;
37 Efl.Gfx.Fill.fill_auto.get;
38 Efl.Gfx.Fill.fill_auto.set;
39 Efl.Gfx.Filter.filter_program.set;
40 Efl.Gfx.View.view_size.get;
41 Evas.Filter.filter_input_alpha;
42 Evas.Filter.filter_input_render;
43 Evas.Filter.filter_dirty;
44 }
45}
diff --git a/src/lib/evas/canvas/efl_canvas_proxy.c b/src/lib/evas/canvas/efl_canvas_proxy.c
index 27d8170a84..e7a0fb1dc9 100644
--- a/src/lib/evas/canvas/efl_canvas_proxy.c
+++ b/src/lib/evas/canvas/efl_canvas_proxy.c
@@ -7,7 +7,7 @@ Eina_Bool
7_evas_image_proxy_source_set(Eo *eo_obj, Evas_Object *eo_src) 7_evas_image_proxy_source_set(Eo *eo_obj, Evas_Object *eo_src)
8{ 8{
9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
11 if (obj->delete_me && eo_src) 11 if (obj->delete_me && eo_src)
12 { 12 {
13 WRN("Setting deleted object %p as image source %p", eo_src, eo_obj); 13 WRN("Setting deleted object %p as image source %p", eo_src, eo_obj);
@@ -65,7 +65,7 @@ _efl_canvas_proxy_source_set(Eo *eo_obj, void *_pd EINA_UNUSED, Evas_Object *eo_
65Evas_Object * 65Evas_Object *
66_evas_image_proxy_source_get(const Eo *eo_obj) 66_evas_image_proxy_source_get(const Eo *eo_obj)
67{ 67{
68 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 68 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
69 return o->cur->source; 69 return o->cur->source;
70} 70}
71 71
@@ -80,7 +80,7 @@ _evas_image_proxy_source_clip_set(Eo *eo_obj, Eina_Bool source_clip)
80{ 80{
81 Evas_Object_Protected_Data *src_obj; 81 Evas_Object_Protected_Data *src_obj;
82 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 82 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
83 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 83 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
84 84
85 source_clip = !!source_clip; 85 source_clip = !!source_clip;
86 if (o->proxy_src_clip == source_clip) return; 86 if (o->proxy_src_clip == source_clip) return;
@@ -102,7 +102,7 @@ _efl_canvas_proxy_source_clip_set(Eo *eo_obj, void *_pd EINA_UNUSED, Eina_Bool s
102Eina_Bool 102Eina_Bool
103_evas_image_proxy_source_clip_get(const Eo *eo_obj) 103_evas_image_proxy_source_clip_get(const Eo *eo_obj)
104{ 104{
105 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 105 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
106 return o->proxy_src_clip; 106 return o->proxy_src_clip;
107} 107}
108 108
@@ -116,7 +116,7 @@ void
116_evas_image_proxy_source_events_set(Eo *eo_obj, Eina_Bool source_events) 116_evas_image_proxy_source_events_set(Eo *eo_obj, Eina_Bool source_events)
117{ 117{
118 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 118 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
119 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 119 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
120 120
121 source_events = !!source_events; 121 source_events = !!source_events;
122 if (obj->proxy->src_events == source_events) return; 122 if (obj->proxy->src_events == source_events) return;
@@ -152,7 +152,7 @@ _efl_canvas_proxy_source_events_get(Eo *eo_obj, void *_pd EINA_UNUSED)
152Evas_Object * 152Evas_Object *
153_evas_object_image_source_get(Evas_Object *eo_obj) 153_evas_object_image_source_get(Evas_Object *eo_obj)
154{ 154{
155 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 155 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
156 return o->cur->source; 156 return o->cur->source;
157} 157}
158 158
@@ -217,7 +217,7 @@ _evas_image_proxy_set(Evas_Object *eo_proxy, Evas_Object *eo_src)
217{ 217{
218 Evas_Object_Protected_Data *src = eo_data_scope_get(eo_src, EVAS_OBJECT_CLASS); 218 Evas_Object_Protected_Data *src = eo_data_scope_get(eo_src, EVAS_OBJECT_CLASS);
219 Evas_Object_Protected_Data *proxy = eo_data_scope_get(eo_proxy, EVAS_OBJECT_CLASS); 219 Evas_Object_Protected_Data *proxy = eo_data_scope_get(eo_proxy, EVAS_OBJECT_CLASS);
220 Evas_Image_Data *o = eo_data_scope_get(eo_proxy, EVAS_IMAGE_CLASS); 220 Evas_Image_Data *o = eo_data_scope_get(eo_proxy, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
221 221
222 _evas_image_file_set(eo_proxy, NULL, NULL); 222 _evas_image_file_set(eo_proxy, NULL, NULL);
223 223
@@ -250,8 +250,8 @@ _proxy_image_get(Evas_Image_Data *o)
250 if (!source) 250 if (!source)
251 return NULL; 251 return NULL;
252 252
253 if (eo_isa(o->cur->source, EVAS_IMAGE_CLASS)) 253 if (eo_isa(o->cur->source, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
254 source_img = eo_data_scope_get(o->cur->source, EVAS_IMAGE_CLASS); 254 source_img = eo_data_scope_get(o->cur->source, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
255 255
256 if (source_img) 256 if (source_img)
257 return source_img->engine_data; 257 return source_img->engine_data;
@@ -267,7 +267,7 @@ _efl_canvas_proxy_efl_gfx_buffer_buffer_map(Eo *eo_obj, void *_pd EINA_UNUSED,
267 Efl_Gfx_Colorspace cspace, int *stride) 267 Efl_Gfx_Colorspace cspace, int *stride)
268{ 268{
269 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 269 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
270 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 270 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
271 int len = 0, s = 0, width = 0, height = 0; 271 int len = 0, s = 0, width = 0, height = 0;
272 void *image, *data = NULL; 272 void *image, *data = NULL;
273 273
@@ -316,7 +316,7 @@ _efl_canvas_proxy_efl_gfx_buffer_buffer_unmap(Eo *eo_obj, void *_pd EINA_UNUSED,
316 void *data, int length) 316 void *data, int length)
317{ 317{
318 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 318 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
319 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 319 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
320 320
321 if (!ENFN->image_data_unmap || !o->engine_data) 321 if (!ENFN->image_data_unmap || !o->engine_data)
322 return EINA_FALSE; 322 return EINA_FALSE;
@@ -334,7 +334,7 @@ void
334_evas_image_proxy_error(Evas_Object *eo_proxy, void *context, void *output, void *surface, 334_evas_image_proxy_error(Evas_Object *eo_proxy, void *context, void *output, void *surface,
335 int x, int y, Eina_Bool do_async) 335 int x, int y, Eina_Bool do_async)
336{ 336{
337 Evas_Image_Data *o = eo_data_scope_get(eo_proxy, EVAS_IMAGE_CLASS); 337 Evas_Image_Data *o = eo_data_scope_get(eo_proxy, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
338 Evas_Object_Protected_Data *proxy; 338 Evas_Object_Protected_Data *proxy;
339 Evas_Func *func; 339 Evas_Func *func;
340 340
diff --git a/src/lib/evas/canvas/efl_canvas_scene3d.c b/src/lib/evas/canvas/efl_canvas_scene3d.c
index c8ce097469..4e3d5f3a91 100644
--- a/src/lib/evas/canvas/efl_canvas_scene3d.c
+++ b/src/lib/evas/canvas/efl_canvas_scene3d.c
@@ -7,7 +7,7 @@ EOLIAN static void
7_efl_canvas_scene3d_scene3d_set(Eo *eo_obj, void *pd EINA_UNUSED, Evas_Canvas3D_Scene *scene) 7_efl_canvas_scene3d_scene3d_set(Eo *eo_obj, void *pd EINA_UNUSED, Evas_Canvas3D_Scene *scene)
8{ 8{
9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 9 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 10 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
11 Evas_Image_Load_Opts lo; 11 Evas_Image_Load_Opts lo;
12 12
13 if (o->cur->scene == scene) return; 13 if (o->cur->scene == scene) return;
@@ -24,7 +24,7 @@ _efl_canvas_scene3d_scene3d_set(Eo *eo_obj, void *pd EINA_UNUSED, Evas_Canvas3D_
24EOLIAN static Evas_Canvas3D_Scene * 24EOLIAN static Evas_Canvas3D_Scene *
25_efl_canvas_scene3d_scene3d_get(Eo *eo_obj, void *pd EINA_UNUSED) 25_efl_canvas_scene3d_scene3d_get(Eo *eo_obj, void *pd EINA_UNUSED)
26{ 26{
27 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 27 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
28 return o->cur->scene; 28 return o->cur->scene;
29} 29}
30 30
@@ -142,7 +142,7 @@ void
142_evas_image_3d_set(Evas_Object *eo_obj, Evas_Canvas3D_Scene *scene) 142_evas_image_3d_set(Evas_Object *eo_obj, Evas_Canvas3D_Scene *scene)
143{ 143{
144 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 144 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
145 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 145 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
146 Evas_Canvas3D_Scene_Data *pd_scene = eo_data_scope_get(scene, 146 Evas_Canvas3D_Scene_Data *pd_scene = eo_data_scope_get(scene,
147 EVAS_CANVAS3D_SCENE_CLASS); 147 EVAS_CANVAS3D_SCENE_CLASS);
148 EINA_COW_WRITE_BEGIN(evas_object_3d_cow, obj->data_3d, Evas_Object_3D_Data, 148 EINA_COW_WRITE_BEGIN(evas_object_3d_cow, obj->data_3d, Evas_Object_3D_Data,
@@ -215,7 +215,7 @@ _efl_canvas_scene3d_efl_gfx_buffer_buffer_map(Eo *eo_obj, void *_pd EINA_UNUSED,
215 int x, int y, int w, int h, 215 int x, int y, int w, int h,
216 Efl_Gfx_Colorspace cspace, int *stride EINA_UNUSED) 216 Efl_Gfx_Colorspace cspace, int *stride EINA_UNUSED)
217{ 217{
218 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 218 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
219 Evas_Public_Data *e; 219 Evas_Public_Data *e;
220 Evas_Canvas3D_Object_Data *pd_parent; 220 Evas_Canvas3D_Object_Data *pd_parent;
221 Evas_Canvas3D_Scene_Data *pd_scene; 221 Evas_Canvas3D_Scene_Data *pd_scene;
diff --git a/src/lib/evas/canvas/evas_canvas3d_texture.c b/src/lib/evas/canvas/evas_canvas3d_texture.c
index 664de1c9c1..289e9ac4c6 100644
--- a/src/lib/evas/canvas/evas_canvas3d_texture.c
+++ b/src/lib/evas/canvas/evas_canvas3d_texture.c
@@ -69,7 +69,7 @@ _texture_proxy_subrender(Evas_Canvas3D_Texture *obj)
69 69
70 source = eo_data_scope_get(pd->source, EVAS_OBJECT_CLASS); 70 source = eo_data_scope_get(pd->source, EVAS_OBJECT_CLASS);
71 71
72 is_image = eo_isa(pd->source, EVAS_IMAGE_CLASS); 72 is_image = eo_isa(pd->source, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
73 73
74 EINA_COW_WRITE_BEGIN(evas_object_proxy_cow, source->proxy, Evas_Object_Proxy_Data, proxy_write) 74 EINA_COW_WRITE_BEGIN(evas_object_proxy_cow, source->proxy, Evas_Object_Proxy_Data, proxy_write)
75 { 75 {
diff --git a/src/lib/evas/canvas/evas_image.eo b/src/lib/evas/canvas/evas_image.eo
index b05f2577f1..974f959fe1 100644
--- a/src/lib/evas/canvas/evas_image.eo
+++ b/src/lib/evas/canvas/evas_image.eo
@@ -1,50 +1,8 @@
1type @extern Evas_Object_Image_Pixels_Get_Cb: __undefined_type; /* FIXME: func pointers are not supported. */ 1class Evas.Image (Efl.Canvas.Image.Internal, Efl.File)
2
3class Evas.Image (Evas.Object, Evas.Filter,
4 Efl.Image, Efl.Gfx.Buffer, Efl.Gfx.Fill, Efl.Gfx.View, Efl.File,
5 Efl.Orientation, Efl.Flipable)
6{ 2{
7 /* Legacy is implement inside Efl.Canvas.Image */ 3 [[Internal class for legacy support of Evas Image.]]
8 legacy_prefix: evas_object_image; 4 data: null;
9 eo_prefix: null;
10 implements { 5 implements {
11 Eo.Base.constructor;
12 Eo.Base.destructor;
13 Eo.Base.dbg_info_get;
14 Eo.Base.finalize;
15 Efl.File.save;
16 Efl.Orientation.orientation.get;
17 Efl.Orientation.orientation.set;
18 Efl.Flipable.flip.set;
19 Efl.Flipable.flip.get;
20 Efl.Image.smooth_scale.set;
21 Efl.Image.smooth_scale.get;
22 Efl.Image.ratio.get;
23 Efl.Image.border.get;
24 Efl.Image.border.set;
25 Efl.Image.border_scale.get;
26 Efl.Image.border_scale.set;
27 Efl.Image.border_center_fill.get;
28 Efl.Image.border_center_fill.set;
29 Efl.Image.scale_hint.get;
30 Efl.Image.scale_hint.set;
31 Efl.Image.content_hint.get;
32 Efl.Image.content_hint.set;
33 Efl.Gfx.Buffer.alpha.get;
34 Efl.Gfx.Buffer.alpha.set;
35 Efl.Gfx.Buffer.buffer_update_add;
36 Efl.Gfx.Buffer.colorspace.get;
37 Efl.Gfx.Fill.fill.set;
38 Efl.Gfx.Fill.fill.get;
39 Efl.Gfx.Fill.fill_auto.get;
40 Efl.Gfx.Fill.fill_auto.set;
41 Efl.Gfx.Filter.filter_program.set;
42 Efl.Gfx.View.view_size.get;
43 Evas.Filter.filter_input_alpha;
44 Evas.Filter.filter_input_render;
45 Evas.Filter.filter_dirty;
46
47 /* FIXME: Efl.File does not belong here */
48 Efl.File.file.set; 6 Efl.File.file.set;
49 Efl.File.file.get; 7 Efl.File.file.get;
50 Efl.File.mmap.set; 8 Efl.File.mmap.set;
diff --git a/src/lib/evas/canvas/evas_image_legacy.c b/src/lib/evas/canvas/evas_image_legacy.c
index 897192ebd6..fe8298a7e0 100644
--- a/src/lib/evas/canvas/evas_image_legacy.c
+++ b/src/lib/evas/canvas/evas_image_legacy.c
@@ -1,4 +1,5 @@
1#include "evas_image_private.h" 1#include "evas_image_private.h"
2#include "evas_image.eo.h"
2 3
3#define EVAS_IMAGE_API(_o, ...) do { \ 4#define EVAS_IMAGE_API(_o, ...) do { \
4 if (EINA_UNLIKELY(!eo_isa(_o, EVAS_IMAGE_CLASS))) { \ 5 if (EINA_UNLIKELY(!eo_isa(_o, EVAS_IMAGE_CLASS))) { \
@@ -47,7 +48,7 @@ evas_object_image_fill_set(Evas_Object *obj,
47 Evas_Coord w, Evas_Coord h) 48 Evas_Coord w, Evas_Coord h)
48{ 49{
49 EVAS_IMAGE_API(obj); 50 EVAS_IMAGE_API(obj);
50 _evas_image_fill_set(obj, eo_data_scope_get(obj, EVAS_IMAGE_CLASS), x, y, w, h); 51 _evas_image_fill_set(obj, eo_data_scope_get(obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS), x, y, w, h);
51} 52}
52 53
53EAPI void 54EAPI void
@@ -157,7 +158,7 @@ EAPI int
157evas_object_image_stride_get(const Evas_Object *obj) 158evas_object_image_stride_get(const Evas_Object *obj)
158{ 159{
159 EVAS_IMAGE_API(obj, 0); 160 EVAS_IMAGE_API(obj, 0);
160 Evas_Image_Data *o = eo_data_scope_get(obj, EVAS_IMAGE_CLASS); 161 Evas_Image_Data *o = eo_data_scope_get(obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
161 return o->cur->image.stride; 162 return o->cur->image.stride;
162} 163}
163 164
@@ -348,7 +349,7 @@ evas_object_image_orient_set(Evas_Object *obj, Evas_Image_Orient orient)
348{ 349{
349 EVAS_IMAGE_API(obj); 350 EVAS_IMAGE_API(obj);
350 351
351 Evas_Image_Data *o = eo_data_scope_get(obj, EVAS_IMAGE_CLASS); 352 Evas_Image_Data *o = eo_data_scope_get(obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
352 _evas_image_orientation_set(obj, o, orient); 353 _evas_image_orientation_set(obj, o, orient);
353} 354}
354 355
@@ -357,7 +358,7 @@ evas_object_image_orient_get(const Evas_Object *obj)
357{ 358{
358 EVAS_IMAGE_API(obj, EVAS_IMAGE_ORIENT_NONE); 359 EVAS_IMAGE_API(obj, EVAS_IMAGE_ORIENT_NONE);
359 360
360 Evas_Image_Data *o = eo_data_scope_get(obj, EVAS_IMAGE_CLASS); 361 Evas_Image_Data *o = eo_data_scope_get(obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
361 362
362 return o->cur->orient; 363 return o->cur->orient;
363} 364}
@@ -480,7 +481,7 @@ EAPI void
480evas_object_image_pixels_get_callback_set(Eo *eo_obj, Evas_Object_Image_Pixels_Get_Cb func, void *data) 481evas_object_image_pixels_get_callback_set(Eo *eo_obj, Evas_Object_Image_Pixels_Get_Cb func, void *data)
481{ 482{
482 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 483 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
483 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 484 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
484 485
485 evas_object_async_block(obj); 486 evas_object_async_block(obj);
486 EINA_COW_PIXEL_WRITE_BEGIN(o, pixi_write) 487 EINA_COW_PIXEL_WRITE_BEGIN(o, pixi_write)
@@ -495,7 +496,7 @@ EAPI void
495evas_object_image_pixels_dirty_set(Eo *eo_obj, Eina_Bool dirty) 496evas_object_image_pixels_dirty_set(Eo *eo_obj, Eina_Bool dirty)
496{ 497{
497 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 498 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
498 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 499 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
499 500
500 evas_object_async_block(obj); 501 evas_object_async_block(obj);
501 if (dirty) o->dirty_pixels = EINA_TRUE; 502 if (dirty) o->dirty_pixels = EINA_TRUE;
@@ -507,7 +508,7 @@ evas_object_image_pixels_dirty_set(Eo *eo_obj, Eina_Bool dirty)
507EAPI Eina_Bool 508EAPI Eina_Bool
508evas_object_image_pixels_dirty_get(const Eo *eo_obj) 509evas_object_image_pixels_dirty_get(const Eo *eo_obj)
509{ 510{
510 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 511 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
511 512
512 return (o->dirty_pixels ? 1 : 0); 513 return (o->dirty_pixels ? 1 : 0);
513} 514}
@@ -516,7 +517,7 @@ EAPI void
516evas_object_image_data_set(Eo *eo_obj, void *data) 517evas_object_image_data_set(Eo *eo_obj, void *data)
517{ 518{
518 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 519 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
519 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 520 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
520 void *p_data; 521 void *p_data;
521 Eina_Bool resize_call = EINA_FALSE; 522 Eina_Bool resize_call = EINA_FALSE;
522 523
@@ -604,7 +605,7 @@ evas_object_image_data_set(Eo *eo_obj, void *data)
604EAPI void* 605EAPI void*
605evas_object_image_data_get(const Eo *eo_obj, Eina_Bool for_writing) 606evas_object_image_data_get(const Eo *eo_obj, Eina_Bool for_writing)
606{ 607{
607 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 608 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
608 int stride = 0; 609 int stride = 0;
609 void *pixels; 610 void *pixels;
610 DATA32 *data; 611 DATA32 *data;
@@ -653,7 +654,7 @@ EAPI void
653evas_object_image_data_copy_set(Eo *eo_obj, void *data) 654evas_object_image_data_copy_set(Eo *eo_obj, void *data)
654{ 655{
655 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 656 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
656 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 657 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
657 658
658 if (!data) return; 659 if (!data) return;
659 evas_object_async_block(obj); 660 evas_object_async_block(obj);
@@ -707,7 +708,7 @@ evas_object_image_size_set(Evas_Object *eo_obj, int w, int h)
707 EVAS_IMAGE_API(eo_obj); 708 EVAS_IMAGE_API(eo_obj);
708 709
709 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 710 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
710 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 711 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
711 int stride = 0; 712 int stride = 0;
712 713
713 if (o->cur->scene) return; 714 if (o->cur->scene) return;
@@ -774,7 +775,7 @@ evas_object_image_colorspace_set(Evas_Object *eo_obj, Evas_Colorspace cspace)
774 EVAS_IMAGE_API(eo_obj); 775 EVAS_IMAGE_API(eo_obj);
775 776
776 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 777 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
777 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 778 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
778 779
779 evas_object_async_block(obj); 780 evas_object_async_block(obj);
780 _evas_image_cleanup(eo_obj, obj, o); 781 _evas_image_cleanup(eo_obj, obj, o);
@@ -795,7 +796,7 @@ evas_object_image_video_surface_set(Evas_Object *eo_obj, Evas_Video_Surface *sur
795 EVAS_IMAGE_LEGACY_API(eo_obj); 796 EVAS_IMAGE_LEGACY_API(eo_obj);
796 797
797 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 798 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
798 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 799 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
799 evas_object_async_block(obj); 800 evas_object_async_block(obj);
800 801
801 _evas_image_cleanup(eo_obj, obj, o); 802 _evas_image_cleanup(eo_obj, obj, o);
@@ -855,7 +856,7 @@ evas_object_image_video_surface_get(const Evas_Object *eo_obj)
855{ 856{
856 EVAS_IMAGE_LEGACY_API(eo_obj, NULL); 857 EVAS_IMAGE_LEGACY_API(eo_obj, NULL);
857 858
858 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 859 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
859 return (!o->video_surface ? NULL : &o->pixels->video); 860 return (!o->video_surface ? NULL : &o->pixels->video);
860} 861}
861 862
@@ -865,7 +866,7 @@ evas_object_image_video_surface_caps_set(Evas_Object *eo_obj, unsigned int caps)
865 EVAS_IMAGE_LEGACY_API(eo_obj); 866 EVAS_IMAGE_LEGACY_API(eo_obj);
866 867
867 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 868 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
868 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 869 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
869 evas_object_async_block(obj); 870 evas_object_async_block(obj);
870 871
871 _evas_image_cleanup(eo_obj, obj, o); 872 _evas_image_cleanup(eo_obj, obj, o);
@@ -883,7 +884,7 @@ evas_object_image_video_surface_caps_get(const Evas_Object *eo_obj)
883{ 884{
884 EVAS_IMAGE_LEGACY_API(eo_obj, 0); 885 EVAS_IMAGE_LEGACY_API(eo_obj, 0);
885 886
886 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 887 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
887 return (!o->video_surface ? 0 : o->pixels->video_caps); 888 return (!o->video_surface ? 0 : o->pixels->video_caps);
888} 889}
889 890
@@ -920,7 +921,7 @@ evas_object_image_source_visible_set(Evas_Object *eo, Eina_Bool visible)
920 Evas_Object_Protected_Data *src_obj; 921 Evas_Object_Protected_Data *src_obj;
921 Evas_Image_Data *o; 922 Evas_Image_Data *o;
922 923
923 o = eo_data_scope_get(eo, EVAS_IMAGE_CLASS); 924 o = eo_data_scope_get(eo, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
924 if (!o->cur->source) return; 925 if (!o->cur->source) return;
925 926
926 visible = !!visible; 927 visible = !!visible;
@@ -952,7 +953,7 @@ evas_object_image_source_visible_get(const Evas_Object *eo)
952 Evas_Image_Data *o; 953 Evas_Image_Data *o;
953 Eina_Bool visible; 954 Eina_Bool visible;
954 955
955 o = eo_data_scope_get(eo, EVAS_IMAGE_CLASS); 956 o = eo_data_scope_get(eo, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
956 if (!o->cur->source) visible = EINA_FALSE; 957 if (!o->cur->source) visible = EINA_FALSE;
957 src_obj = eo_data_scope_get(o->cur->source, EVAS_OBJECT_CLASS); 958 src_obj = eo_data_scope_get(o->cur->source, EVAS_OBJECT_CLASS);
958 if (src_obj) visible = !src_obj->proxy->src_invisible; 959 if (src_obj) visible = !src_obj->proxy->src_invisible;
@@ -981,7 +982,7 @@ evas_object_image_data_convert(Evas_Object *eo_obj, Evas_Colorspace to_cspace)
981 } 982 }
982 983
983 evas_object_async_block(obj); 984 evas_object_async_block(obj);
984 o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 985 o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
985 if ((o->preloading) && (o->engine_data)) 986 if ((o->preloading) && (o->engine_data))
986 { 987 {
987 o->preloading = EINA_FALSE; 988 o->preloading = EINA_FALSE;
@@ -1010,7 +1011,7 @@ evas_object_image_reload(Evas_Object *eo_obj)
1010 Evas_Image_Data *o; 1011 Evas_Image_Data *o;
1011 1012
1012 evas_object_async_block(obj); 1013 evas_object_async_block(obj);
1013 o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 1014 o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
1014 if ((o->preloading) && (o->engine_data)) 1015 if ((o->preloading) && (o->engine_data))
1015 { 1016 {
1016 o->preloading = EINA_FALSE; 1017 o->preloading = EINA_FALSE;
@@ -1053,7 +1054,7 @@ evas_object_image_pixels_import(Evas_Object *eo_obj, Evas_Pixel_Import_Source *p
1053 } 1054 }
1054 1055
1055 evas_object_async_block(obj); 1056 evas_object_async_block(obj);
1056 o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 1057 o = eo_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
1057 _evas_image_cleanup(eo_obj, obj, o); 1058 _evas_image_cleanup(eo_obj, obj, o);
1058 if ((pixels->w != o->cur->image.w) || (pixels->h != o->cur->image.h)) return EINA_FALSE; 1059 if ((pixels->w != o->cur->image.w) || (pixels->h != o->cur->image.h)) return EINA_FALSE;
1059 1060
@@ -1118,3 +1119,40 @@ evas_object_image_alpha_mask_set(Evas_Object *eo_obj EINA_UNUSED, Eina_Bool isma
1118 DBG("This function is not implemented, has never been and never will be."); 1119 DBG("This function is not implemented, has never been and never will be.");
1119 EVAS_IMAGE_LEGACY_API(eo_obj); 1120 EVAS_IMAGE_LEGACY_API(eo_obj);
1120} 1121}
1122
1123
1124/* FIXME: Temporarily allow efl_file_ APIs on Evas.Image.
1125 * They don't belong here, as only Efl.Canvas.Image should support them.
1126 * Elm.Image uses them, though, instead of using the legacy APIs...
1127 */
1128
1129EOLIAN static Eina_Bool
1130_evas_image_efl_file_file_set(Eo *obj, void *pd EINA_UNUSED, const char *file, const char *key)
1131{
1132 ERR("efl_file_set shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
1133 return _evas_image_file_set(obj, file, key);
1134}
1135
1136EOLIAN static void
1137_evas_image_efl_file_file_get(Eo *obj, void *pd EINA_UNUSED, const char **file, const char **key)
1138{
1139 ERR("efl_file_get shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
1140 _evas_image_file_get(obj, file, key);
1141}
1142
1143EOLIAN static Eina_Bool
1144_evas_image_efl_file_mmap_set(Eo *obj, void *pd EINA_UNUSED, const Eina_File *f, const char *key)
1145{
1146 ERR("efl_file_mmap_set shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
1147 return _evas_image_mmap_set(obj, f, key);
1148}
1149
1150
1151EOLIAN static void
1152_evas_image_efl_file_mmap_get(Eo *obj, void *pd EINA_UNUSED, const Eina_File **f, const char **key)
1153{
1154 ERR("efl_file_mmap_get shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
1155 _evas_image_mmap_get(obj, f, key);
1156}
1157
1158#include "canvas/evas_image.eo.c"
diff --git a/src/lib/evas/canvas/evas_main.c b/src/lib/evas/canvas/evas_main.c
index 516c418d86..0a1b6e8c16 100644
--- a/src/lib/evas/canvas/evas_main.c
+++ b/src/lib/evas/canvas/evas_main.c
@@ -736,7 +736,7 @@ _image_data_unset(Evas_Object_Protected_Data *obj, Eina_List **list)
736 FREE; \ 736 FREE; \
737 data->engine_data = NULL;\ 737 data->engine_data = NULL;\
738 } 738 }
739 CHECK(EVAS_IMAGE_CLASS, Evas_Image_Data, 739 CHECK(EFL_CANVAS_IMAGE_INTERNAL_CLASS, Evas_Image_Data,
740 ENFN->image_free(ENDT, data->engine_data)) 740 ENFN->image_free(ENDT, data->engine_data))
741 else CHECK(EVAS_VG_CLASS, Evas_VG_Data, 741 else CHECK(EVAS_VG_CLASS, Evas_VG_Data,
742 obj->layer->evas->engine.func->ector_free(data->engine_data)) 742 obj->layer->evas->engine.func->ector_free(data->engine_data))
@@ -802,7 +802,7 @@ _image_data_regenerate(Evas_Object *eo_obj)
802 STRUCT *data = eo_data_scope_get(eo_obj, TYPE);\ 802 STRUCT *data = eo_data_scope_get(eo_obj, TYPE);\
803 REGEN; \ 803 REGEN; \
804 } 804 }
805 CHECK(EVAS_IMAGE_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data)) 805 CHECK(EFL_CANVAS_IMAGE_INTERNAL_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data))
806 else CHECK(EFL_CANVAS_IMAGE_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data)) 806 else CHECK(EFL_CANVAS_IMAGE_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data))
807 else CHECK(EFL_CANVAS_SCENE3D_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data)) 807 else CHECK(EFL_CANVAS_SCENE3D_CLASS, Evas_Image_Data, _image_image_data_regenerate(eo_obj, obj, data))
808 //else CHECK(EVAS_VG_CLASS, Evas_VG_Data,) 808 //else CHECK(EVAS_VG_CLASS, Evas_VG_Data,)
diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c
index bb192b9868..adf7eca1ab 100644
--- a/src/lib/evas/canvas/evas_object_image.c
+++ b/src/lib/evas/canvas/evas_object_image.c
@@ -1,6 +1,6 @@
1#include "evas_image_private.h" 1#include "evas_image_private.h"
2 2
3#define MY_CLASS EVAS_IMAGE_CLASS 3#define MY_CLASS EFL_CANVAS_IMAGE_INTERNAL_CLASS
4#define MY_CLASS_NAME "Evas_Image" 4#define MY_CLASS_NAME "Evas_Image"
5 5
6/* private magic number for image objects */ 6/* private magic number for image objects */
@@ -169,7 +169,7 @@ _init_cow(void)
169} 169}
170 170
171EOLIAN static Eo * 171EOLIAN static Eo *
172_evas_image_eo_base_constructor(Eo *eo_obj, Evas_Image_Data *o) 172_efl_canvas_image_internal_eo_base_constructor(Eo *eo_obj, Evas_Image_Data *o)
173{ 173{
174 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 174 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
175 Evas_Colorspace cspace; 175 Evas_Colorspace cspace;
@@ -199,7 +199,7 @@ _evas_image_eo_base_constructor(Eo *eo_obj, Evas_Image_Data *o)
199} 199}
200 200
201EOLIAN static Eo * 201EOLIAN static Eo *
202_evas_image_eo_base_finalize(Eo *eo_obj, Evas_Image_Data *o) 202_efl_canvas_image_internal_eo_base_finalize(Eo *eo_obj, Evas_Image_Data *o)
203{ 203{
204 if (!o->filled_set) 204 if (!o->filled_set)
205 efl_gfx_fill_auto_set(eo_obj, EINA_TRUE); 205 efl_gfx_fill_auto_set(eo_obj, EINA_TRUE);
@@ -429,7 +429,7 @@ _get_image_orient_from_orient_flip(Efl_Orient orient, Efl_Flip flip)
429} 429}
430 430
431EOLIAN static void 431EOLIAN static void
432_evas_image_efl_orientation_orientation_set(Eo *obj, Evas_Image_Data *o, Efl_Orient dir) 432_efl_canvas_image_internal_efl_orientation_orientation_set(Eo *obj, Evas_Image_Data *o, Efl_Orient dir)
433{ 433{
434 Evas_Image_Orient orient; 434 Evas_Image_Orient orient;
435 435
@@ -440,13 +440,13 @@ _evas_image_efl_orientation_orientation_set(Eo *obj, Evas_Image_Data *o, Efl_Ori
440} 440}
441 441
442EOLIAN static Efl_Orient 442EOLIAN static Efl_Orient
443_evas_image_efl_orientation_orientation_get(Eo *obj EINA_UNUSED, Evas_Image_Data *o) 443_efl_canvas_image_internal_efl_orientation_orientation_get(Eo *obj EINA_UNUSED, Evas_Image_Data *o)
444{ 444{
445 return o->orient_value; 445 return o->orient_value;
446} 446}
447 447
448EOLIAN static void 448EOLIAN static void
449_evas_image_efl_flipable_flip_set(Eo *obj, Evas_Image_Data *o, Efl_Flip flip) 449_efl_canvas_image_internal_efl_flipable_flip_set(Eo *obj, Evas_Image_Data *o, Efl_Flip flip)
450{ 450{
451 Evas_Image_Orient orient; 451 Evas_Image_Orient orient;
452 452
@@ -457,13 +457,13 @@ _evas_image_efl_flipable_flip_set(Eo *obj, Evas_Image_Data *o, Efl_Flip flip)
457} 457}
458 458
459EOLIAN static Efl_Flip 459EOLIAN static Efl_Flip
460_evas_image_efl_flipable_flip_get(Eo *obj EINA_UNUSED, Evas_Image_Data *o) 460_efl_canvas_image_internal_efl_flipable_flip_get(Eo *obj EINA_UNUSED, Evas_Image_Data *o)
461{ 461{
462 return o->flip_value; 462 return o->flip_value;
463} 463}
464 464
465EOLIAN static void 465EOLIAN static void
466_evas_image_eo_base_dbg_info_get(Eo *eo_obj, Evas_Image_Data *o, Eo_Dbg_Info *root) 466_efl_canvas_image_internal_eo_base_dbg_info_get(Eo *eo_obj, Evas_Image_Data *o, Eo_Dbg_Info *root)
467{ 467{
468 eo_dbg_info_get(eo_super(eo_obj, MY_CLASS), root); 468 eo_dbg_info_get(eo_super(eo_obj, MY_CLASS), root);
469 Eo_Dbg_Info *group = EO_DBG_INFO_LIST_APPEND(root, MY_CLASS_NAME); 469 Eo_Dbg_Info *group = EO_DBG_INFO_LIST_APPEND(root, MY_CLASS_NAME);
@@ -490,7 +490,7 @@ _evas_image_eo_base_dbg_info_get(Eo *eo_obj, Evas_Image_Data *o, Eo_Dbg_Info *ro
490} 490}
491 491
492EOLIAN static void 492EOLIAN static void
493_evas_image_efl_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, int t, int b) 493_efl_canvas_image_internal_efl_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, int t, int b)
494{ 494{
495 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 495 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
496 496
@@ -517,7 +517,7 @@ _evas_image_efl_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, i
517} 517}
518 518
519EOLIAN static void 519EOLIAN static void
520_evas_image_efl_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *l, int *r, int *t, int *b) 520_efl_canvas_image_internal_efl_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *l, int *r, int *t, int *b)
521{ 521{
522 if (l) *l = o->cur->border.l; 522 if (l) *l = o->cur->border.l;
523 if (r) *r = o->cur->border.r; 523 if (r) *r = o->cur->border.r;
@@ -526,7 +526,7 @@ _evas_image_efl_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int
526} 526}
527 527
528EOLIAN static void 528EOLIAN static void
529_evas_image_efl_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Gfx_Border_Fill_Mode _fill) 529_efl_canvas_image_internal_efl_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Gfx_Border_Fill_Mode _fill)
530{ 530{
531 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 531 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
532 Evas_Border_Fill_Mode fill = (Evas_Border_Fill_Mode) _fill; 532 Evas_Border_Fill_Mode fill = (Evas_Border_Fill_Mode) _fill;
@@ -542,13 +542,13 @@ _evas_image_efl_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Efl
542} 542}
543 543
544EOLIAN static Efl_Gfx_Border_Fill_Mode 544EOLIAN static Efl_Gfx_Border_Fill_Mode
545_evas_image_efl_image_border_center_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 545_efl_canvas_image_internal_efl_image_border_center_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
546{ 546{
547 return (Efl_Gfx_Border_Fill_Mode) o->cur->border.fill; 547 return (Efl_Gfx_Border_Fill_Mode) o->cur->border.fill;
548} 548}
549 549
550EOLIAN static void 550EOLIAN static void
551_evas_image_efl_gfx_fill_fill_auto_set(Eo *eo_obj, Evas_Image_Data* o, Eina_Bool setting) 551_efl_canvas_image_internal_efl_gfx_fill_fill_auto_set(Eo *eo_obj, Evas_Image_Data* o, Eina_Bool setting)
552{ 552{
553 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 553 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
554 setting = !!setting; 554 setting = !!setting;
@@ -574,13 +574,13 @@ _evas_image_efl_gfx_fill_fill_auto_set(Eo *eo_obj, Evas_Image_Data* o, Eina_Bool
574} 574}
575 575
576EOLIAN static Eina_Bool 576EOLIAN static Eina_Bool
577_evas_image_efl_gfx_fill_fill_auto_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 577_efl_canvas_image_internal_efl_gfx_fill_fill_auto_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
578{ 578{
579 return o->filled; 579 return o->filled;
580} 580}
581 581
582EOLIAN static void 582EOLIAN static void
583_evas_image_efl_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double scale) 583_efl_canvas_image_internal_efl_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double scale)
584{ 584{
585 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 585 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
586 586
@@ -595,7 +595,7 @@ _evas_image_efl_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double sc
595} 595}
596 596
597EOLIAN static double 597EOLIAN static double
598_evas_image_efl_image_border_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 598_efl_canvas_image_internal_efl_image_border_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
599{ 599{
600 return o->cur->border.scale; 600 return o->cur->border.scale;
601} 601}
@@ -631,7 +631,7 @@ _evas_image_fill_set(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h)
631} 631}
632 632
633EOLIAN static void 633EOLIAN static void
634_evas_image_efl_gfx_fill_fill_set(Eo *eo_obj, Evas_Image_Data *o, 634_efl_canvas_image_internal_efl_gfx_fill_fill_set(Eo *eo_obj, Evas_Image_Data *o,
635 int x, int y, int w, int h) 635 int x, int y, int w, int h)
636{ 636{
637 // Should (0,0,0,0) reset the filled flag to true? 637 // Should (0,0,0,0) reset the filled flag to true?
@@ -641,7 +641,7 @@ _evas_image_efl_gfx_fill_fill_set(Eo *eo_obj, Evas_Image_Data *o,
641} 641}
642 642
643EOLIAN static void 643EOLIAN static void
644_evas_image_efl_gfx_fill_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, 644_efl_canvas_image_internal_efl_gfx_fill_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o,
645 int *x, int *y, int *w, int *h) 645 int *x, int *y, int *w, int *h)
646{ 646{
647 if (x) *x = o->cur->fill.x; 647 if (x) *x = o->cur->fill.x;
@@ -651,7 +651,7 @@ _evas_image_efl_gfx_fill_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o,
651} 651}
652 652
653EOLIAN static void 653EOLIAN static void
654_evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, int *h) 654_efl_canvas_image_internal_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, int *h)
655{ 655{
656 int uvw, uvh; 656 int uvw, uvh;
657 Evas_Object_Protected_Data *source = NULL; 657 Evas_Object_Protected_Data *source = NULL;
@@ -693,7 +693,7 @@ _evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, i
693} 693}
694 694
695EOLIAN static void 695EOLIAN static void
696_evas_image_efl_gfx_buffer_buffer_update_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h) 696_efl_canvas_image_internal_efl_gfx_buffer_buffer_update_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h)
697{ 697{
698 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 698 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
699 Eina_Rectangle *r; 699 Eina_Rectangle *r;
@@ -736,7 +736,7 @@ _evas_image_efl_gfx_buffer_buffer_update_add(Eo *eo_obj, Evas_Image_Data *o, int
736} 736}
737 737
738EOLIAN static void 738EOLIAN static void
739_evas_image_efl_gfx_buffer_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool has_alpha) 739_efl_canvas_image_internal_efl_gfx_buffer_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool has_alpha)
740{ 740{
741 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 741 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
742 742
@@ -782,13 +782,13 @@ _evas_image_efl_gfx_buffer_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool h
782} 782}
783 783
784EOLIAN static Eina_Bool 784EOLIAN static Eina_Bool
785_evas_image_efl_gfx_buffer_alpha_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 785_efl_canvas_image_internal_efl_gfx_buffer_alpha_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
786{ 786{
787 return o->cur->has_alpha; 787 return o->cur->has_alpha;
788} 788}
789 789
790EOLIAN static void 790EOLIAN static void
791_evas_image_efl_image_smooth_scale_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool smooth_scale) 791_efl_canvas_image_internal_efl_image_smooth_scale_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool smooth_scale)
792{ 792{
793 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 793 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
794 794
@@ -805,20 +805,20 @@ _evas_image_efl_image_smooth_scale_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool
805} 805}
806 806
807EOLIAN static Eina_Bool 807EOLIAN static Eina_Bool
808_evas_image_efl_image_smooth_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 808_efl_canvas_image_internal_efl_image_smooth_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
809{ 809{
810 return o->cur->smooth_scale; 810 return o->cur->smooth_scale;
811} 811}
812 812
813EOLIAN static double 813EOLIAN static double
814_evas_image_efl_image_ratio_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 814_efl_canvas_image_internal_efl_image_ratio_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
815{ 815{
816 if (!o->cur->image.h) return 1.0; 816 if (!o->cur->image.h) return 1.0;
817 return (double) o->cur->image.w / (double) o->cur->image.h; 817 return (double) o->cur->image.w / (double) o->cur->image.h;
818} 818}
819 819
820EOLIAN static Eina_Bool 820EOLIAN static Eina_Bool
821_evas_image_efl_file_save(const Eo *eo_obj, Evas_Image_Data *o, const char *file, const char *key, const char *flags) 821_efl_canvas_image_internal_efl_file_save(const Eo *eo_obj, Evas_Image_Data *o, const char *file, const char *key, const char *flags)
822{ 822{
823 DATA32 *data = NULL; 823 DATA32 *data = NULL;
824 int quality = 80, compress = 9, ok = 0; 824 int quality = 80, compress = 9, ok = 0;
@@ -1002,7 +1002,7 @@ _evas_image_efl_file_save(const Eo *eo_obj, Evas_Image_Data *o, const char *file
1002} 1002}
1003 1003
1004EOLIAN static Efl_Gfx_Colorspace 1004EOLIAN static Efl_Gfx_Colorspace
1005_evas_image_efl_gfx_buffer_colorspace_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1005_efl_canvas_image_internal_efl_gfx_buffer_colorspace_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1006{ 1006{
1007 return (Efl_Gfx_Colorspace) o->cur->cspace; 1007 return (Efl_Gfx_Colorspace) o->cur->cspace;
1008} 1008}
@@ -1016,7 +1016,7 @@ _on_image_native_surface_del(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_O
1016Eina_Bool 1016Eina_Bool
1017_evas_image_native_surface_set(Eo *eo_obj, Evas_Native_Surface *surf) 1017_evas_image_native_surface_set(Eo *eo_obj, Evas_Native_Surface *surf)
1018{ 1018{
1019 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 1019 Evas_Image_Data *o = eo_data_scope_get(eo_obj, MY_CLASS);
1020 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1020 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1021 evas_object_async_block(obj); 1021 evas_object_async_block(obj);
1022 evas_object_event_callback_del_full 1022 evas_object_event_callback_del_full
@@ -1039,7 +1039,7 @@ Evas_Native_Surface *
1039_evas_image_native_surface_get(const Evas_Object *eo_obj) 1039_evas_image_native_surface_get(const Evas_Object *eo_obj)
1040{ 1040{
1041 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1041 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1042 Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); 1042 Evas_Image_Data *o = eo_data_scope_get(eo_obj, MY_CLASS);
1043 Evas_Native_Surface *surf = NULL; 1043 Evas_Native_Surface *surf = NULL;
1044 1044
1045 if (ENFN->image_native_get) 1045 if (ENFN->image_native_get)
@@ -1049,7 +1049,7 @@ _evas_image_native_surface_get(const Evas_Object *eo_obj)
1049} 1049}
1050 1050
1051EOLIAN static void 1051EOLIAN static void
1052_evas_image_efl_image_scale_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image_Scale_Hint hint) 1052_efl_canvas_image_internal_efl_image_scale_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image_Scale_Hint hint)
1053{ 1053{
1054 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1054 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1055 evas_object_async_block(obj); 1055 evas_object_async_block(obj);
@@ -1076,13 +1076,13 @@ _evas_image_efl_image_scale_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image_S
1076} 1076}
1077 1077
1078EOLIAN static Efl_Image_Scale_Hint 1078EOLIAN static Efl_Image_Scale_Hint
1079_evas_image_efl_image_scale_hint_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1079_efl_canvas_image_internal_efl_image_scale_hint_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1080{ 1080{
1081 return o->scale_hint; 1081 return o->scale_hint;
1082} 1082}
1083 1083
1084EOLIAN static void 1084EOLIAN static void
1085_evas_image_efl_image_content_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image_Content_Hint hint) 1085_efl_canvas_image_internal_efl_image_content_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image_Content_Hint hint)
1086{ 1086{
1087 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1087 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1088 evas_object_async_block(obj); 1088 evas_object_async_block(obj);
@@ -1109,7 +1109,7 @@ _evas_image_efl_image_content_hint_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Image
1109} 1109}
1110 1110
1111EOLIAN static Efl_Image_Content_Hint 1111EOLIAN static Efl_Image_Content_Hint
1112_evas_image_efl_image_content_hint_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1112_efl_canvas_image_internal_efl_image_content_hint_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1113{ 1113{
1114 return o->content_hint; 1114 return o->content_hint;
1115} 1115}
@@ -1365,7 +1365,7 @@ evas_object_image_init(Evas_Object *eo_obj)
1365} 1365}
1366 1366
1367EOLIAN static void 1367EOLIAN static void
1368_evas_image_eo_base_destructor(Eo *eo_obj, Evas_Image_Data *o EINA_UNUSED) 1368_efl_canvas_image_internal_eo_base_destructor(Eo *eo_obj, Evas_Image_Data *o EINA_UNUSED)
1369{ 1369{
1370 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1370 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1371 1371
@@ -1380,7 +1380,7 @@ _evas_object_image_free(Evas_Object *obj)
1380{ 1380{
1381 Evas_Image_Data *o; 1381 Evas_Image_Data *o;
1382 1382
1383 EINA_SAFETY_ON_FALSE_RETURN(eo_isa(obj, EVAS_IMAGE_CLASS)); 1383 EINA_SAFETY_ON_FALSE_RETURN(eo_isa(obj, MY_CLASS));
1384 1384
1385 o = eo_data_scope_get(obj, MY_CLASS); 1385 o = eo_data_scope_get(obj, MY_CLASS);
1386 1386
@@ -1621,7 +1621,7 @@ evas_process_dirty_pixels(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj,
1621} 1621}
1622 1622
1623EOLIAN static void 1623EOLIAN static void
1624_evas_image_evas_filter_filter_dirty(Eo *eo_obj, Evas_Image_Data *o) 1624_efl_canvas_image_internal_evas_filter_filter_dirty(Eo *eo_obj, Evas_Image_Data *o)
1625{ 1625{
1626 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1626 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1627 1627
@@ -1630,24 +1630,24 @@ _evas_image_evas_filter_filter_dirty(Eo *eo_obj, Evas_Image_Data *o)
1630} 1630}
1631 1631
1632EOLIAN static Eina_Bool 1632EOLIAN static Eina_Bool
1633_evas_image_evas_filter_filter_input_alpha(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o EINA_UNUSED) 1633_efl_canvas_image_internal_evas_filter_filter_input_alpha(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o EINA_UNUSED)
1634{ 1634{
1635 return EINA_FALSE; 1635 return EINA_FALSE;
1636} 1636}
1637 1637
1638EOLIAN static void 1638EOLIAN static void
1639_evas_image_efl_gfx_filter_filter_program_set(Eo *obj, Evas_Image_Data *pd, 1639_efl_canvas_image_internal_efl_gfx_filter_filter_program_set(Eo *obj, Evas_Image_Data *pd,
1640 const char *code, const char *name) 1640 const char *code, const char *name)
1641{ 1641{
1642 pd->has_filter = (code != NULL); 1642 pd->has_filter = (code != NULL);
1643 efl_gfx_filter_program_set(eo_super(obj, MY_CLASS), code, name); 1643 efl_gfx_filter_program_set(eo_super(obj, MY_CLASS), code, name);
1644} 1644}
1645 1645
1646EOLIAN static Eina_Bool 1646EOLIAN static Eina_Bool
1647_evas_image_evas_filter_filter_input_render(Eo *eo_obj, Evas_Image_Data *o, 1647_efl_canvas_image_internal_evas_filter_filter_input_render(Eo *eo_obj, Evas_Image_Data *o,
1648 void *_filter, void *context, 1648 void *_filter, void *context,
1649 int l, int r EINA_UNUSED, int t, int b EINA_UNUSED, 1649 int l, int r EINA_UNUSED, int t, int b EINA_UNUSED,
1650 Eina_Bool do_async) 1650 Eina_Bool do_async)
1651{ 1651{
1652 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1652 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1653 Evas_Filter_Context *filter = _filter; 1653 Evas_Filter_Context *filter = _filter;
@@ -3276,7 +3276,7 @@ _evas_object_image_video_overlay_do(Evas_Object *eo_obj)
3276void * 3276void *
3277_evas_object_image_surface_get(Evas_Object *eo, Evas_Object_Protected_Data *obj) 3277_evas_object_image_surface_get(Evas_Object *eo, Evas_Object_Protected_Data *obj)
3278{ 3278{
3279 Evas_Image_Data *pd = eo_data_scope_get(eo, EVAS_IMAGE_CLASS); 3279 Evas_Image_Data *pd = eo_data_scope_get(eo, MY_CLASS);
3280 3280
3281 if (pd->engine_data && 3281 if (pd->engine_data &&
3282 (pd->cur->image.w == obj->cur->geometry.w) && 3282 (pd->cur->image.w == obj->cur->geometry.w) &&
@@ -3301,41 +3301,6 @@ _evas_object_image_surface_get(Evas_Object *eo, Evas_Object_Protected_Data *obj)
3301 return pd->engine_data; 3301 return pd->engine_data;
3302} 3302}
3303 3303
3304/* FIXME: Temporarily allow efl_file_ APIs on Evas.Image. 3304#include "canvas/efl_canvas_image_internal.eo.c"
3305 * They don't belong here, as only Efl.Canvas.Image should support them.
3306 * Elm.Image uses them, though, instead of using the legacy APIs...
3307 */
3308
3309EOLIAN static Eina_Bool
3310_evas_image_efl_file_file_set(Eo *obj, Evas_Image_Data *pd EINA_UNUSED, const char *file, const char *key)
3311{
3312 DBG("efl_file_set shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
3313 return _evas_image_file_set(obj, file, key);
3314}
3315
3316EOLIAN static void
3317_evas_image_efl_file_file_get(Eo *obj, Evas_Image_Data *pd EINA_UNUSED, const char **file, const char **key)
3318{
3319 DBG("efl_file_get shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
3320 _evas_image_file_get(obj, file, key);
3321}
3322
3323EOLIAN static Eina_Bool
3324_evas_image_efl_file_mmap_set(Eo *obj, Evas_Image_Data *pd EINA_UNUSED, const Eina_File *f, const char *key)
3325{
3326 DBG("efl_file_mmap_set shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
3327 return _evas_image_mmap_set(obj, f, key);
3328}
3329
3330
3331EOLIAN static void
3332_evas_image_efl_file_mmap_get(Eo *obj, Evas_Image_Data *pd EINA_UNUSED, const Eina_File **f, const char **key)
3333{
3334 DBG("efl_file_mmap_get shouldn't be used on Evas.Image. please switch to Efl.Canvas.Image");
3335 _evas_image_mmap_get(obj, f, key);
3336}
3337
3338
3339#include "canvas/evas_image.eo.c"
3340 3305
3341/* vim:set ts=8 sw=3 sts=3 expandtab cino=>5n-2f0^-2{2(0W1st0 :*/ 3306/* vim:set ts=8 sw=3 sts=3 expandtab cino=>5n-2f0^-2{2(0W1st0 :*/
diff --git a/src/lib/evas/canvas/evas_object_main.c b/src/lib/evas/canvas/evas_object_main.c
index 7388293da7..33c8f1fa3d 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -244,7 +244,7 @@ evas_object_free(Evas_Object *eo_obj, int clean_layer)
244 244
245 int was_smart_child = 0; 245 int was_smart_child = 0;
246 246
247 if (eo_isa(eo_obj, EVAS_IMAGE_CLASS)) 247 if (eo_isa(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
248 _evas_object_image_free(eo_obj); 248 _evas_object_image_free(eo_obj);
249 evas_object_map_set(eo_obj, NULL); 249 evas_object_map_set(eo_obj, NULL);
250 if (obj->map->prev.map) evas_map_free(obj->map->prev.map); 250 if (obj->map->prev.map) evas_map_free(obj->map->prev.map);
@@ -795,7 +795,7 @@ _evas_object_eo_base_destructor(Eo *eo_obj, Evas_Object_Protected_Data *obj)
795 /* FIXME: Proxies should listen to source death */ 795 /* FIXME: Proxies should listen to source death */
796 EINA_LIST_FOREACH_SAFE(obj->proxy->proxies, l, l2, proxy) 796 EINA_LIST_FOREACH_SAFE(obj->proxy->proxies, l, l2, proxy)
797 { 797 {
798 if (eo_isa(proxy, EVAS_IMAGE_CLASS)) 798 if (eo_isa(proxy, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
799 evas_object_image_source_unset(proxy); 799 evas_object_image_source_unset(proxy);
800 if (eo_isa(proxy, EFL_GFX_FILTER_INTERFACE)) 800 if (eo_isa(proxy, EFL_GFX_FILTER_INTERFACE))
801 efl_gfx_filter_source_set(proxy, NULL, eo_obj); 801 efl_gfx_filter_source_set(proxy, NULL, eo_obj);
diff --git a/src/lib/evas/canvas/evas_render.c b/src/lib/evas/canvas/evas_render.c
index 8b61d8524f..3809b53b8a 100644
--- a/src/lib/evas/canvas/evas_render.c
+++ b/src/lib/evas/canvas/evas_render.c
@@ -1871,7 +1871,7 @@ evas_render_proxy_subrender(Evas *eo_e, Evas_Object *eo_source, Evas_Object *eo_
1871 ENFN->rectangle_draw(ENDT, ctx, proxy_write->surface, 0, 0, w, h, do_async); 1871 ENFN->rectangle_draw(ENDT, ctx, proxy_write->surface, 0, 0, w, h, do_async);
1872 ENFN->context_free(ENDT, ctx); 1872 ENFN->context_free(ENDT, ctx);
1873 1873
1874 if (eo_isa(eo_proxy, EVAS_IMAGE_CLASS)) 1874 if (eo_isa(eo_proxy, EFL_CANVAS_IMAGE_INTERNAL_CLASS))
1875 source_clip = _evas_image_proxy_source_clip_get(eo_proxy); 1875 source_clip = _evas_image_proxy_source_clip_get(eo_proxy);
1876 1876
1877 Evas_Proxy_Render_Data proxy_render_data = { 1877 Evas_Proxy_Render_Data proxy_render_data = {
@@ -1927,7 +1927,7 @@ evas_render_mask_subrender(Evas_Public_Data *evas,
1927 1927
1928 RD(level, "evas_render_mask_subrender(%p, prev: %p)\n", mask, prev_mask); 1928 RD(level, "evas_render_mask_subrender(%p, prev: %p)\n", mask, prev_mask);
1929 1929
1930 is_image = eo_isa(mask->object, EVAS_IMAGE_CLASS); 1930 is_image = eo_isa(mask->object, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
1931 1931
1932 x = mask->cur->geometry.x; 1932 x = mask->cur->geometry.x;
1933 y = mask->cur->geometry.y; 1933 y = mask->cur->geometry.y;
diff --git a/src/tests/evas/evas_test_image.c b/src/tests/evas/evas_test_image.c
index 59d8e101f2..5d4b8aadd0 100644
--- a/src/tests/evas/evas_test_image.c
+++ b/src/tests/evas/evas_test_image.c
@@ -645,7 +645,7 @@ START_TEST(evas_object_image_defaults)
645 eo_del(o); 645 eo_del(o);
646 646
647 /* test eo defaults */ 647 /* test eo defaults */
648 o = eo_add(EVAS_IMAGE_CLASS, e); 648 o = eo_add(EFL_CANVAS_IMAGE_CLASS, e);
649 fail_if(!efl_gfx_fill_auto_get(o)); 649 fail_if(!efl_gfx_fill_auto_get(o));
650 eo_del(o); 650 eo_del(o);
651 651