From: Cedric BAIL Date: Fri, 3 Apr 2015 14:34:26 +0000 (+0200) Subject: evas: removing the ability to load file in Evas_Object_VG for now. X-Git-Tag: v1.14.0-alpha1~44^2~25 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=013b18ea6a5aa643a5e3aa759ea868ea1782632f;p=platform%2Fupstream%2Fefl.git evas: removing the ability to load file in Evas_Object_VG for now. Without events and animation it is not really useful and that can only be done with a library on top of Ecore. --- diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am index 77d1721..2183302 100644 --- a/src/Makefile_Evas.am +++ b/src/Makefile_Evas.am @@ -150,8 +150,7 @@ lib/evas/canvas/evas_stats.c \ lib/evas/canvas/evas_touch_point.c \ lib/evas/canvas/evas_map.c \ lib/evas/canvas/evas_gl.c \ -lib/evas/canvas/evas_out.c \ -lib/evas/canvas/evas_vg_loader_svg.c +lib/evas/canvas/evas_out.c # Cache lib_evas_libevas_la_SOURCES += \ diff --git a/src/lib/evas/canvas/evas_object_vg.c b/src/lib/evas/canvas/evas_object_vg.c index afbe045..57d4090 100644 --- a/src/lib/evas/canvas/evas_object_vg.c +++ b/src/lib/evas/canvas/evas_object_vg.c @@ -19,10 +19,6 @@ struct _Evas_VG_Data void *engine_data; Efl_VG *root; - /* Opening an SVG file (could actually be inside an eet section */ - Eina_File *f; - const char *key; - Eina_Rectangle fill; unsigned int width, height; @@ -375,72 +371,6 @@ evas_object_vg_was_opaque(Evas_Object *eo_obj EINA_UNUSED, return 0; } - -static Eina_Bool -_evas_vg_efl_file_mmap_set(Eo *obj EINA_UNUSED, Evas_VG_Data *pd, - const Eina_File *f, const char *key) -{ - Eina_File *tmp; - - if (f == pd->f && - ((key == NULL && pd->key == NULL) || - (key != NULL && pd->key != NULL && !strcmp(key, pd->key)))) - return EINA_FALSE; - - tmp = f ? eina_file_dup(f) : NULL; - - if (tmp) - { - if (!evas_vg_loader_svg(obj, tmp, NULL)) - { - eina_file_close(tmp); - return EINA_FALSE; - } - } - - // it succeeded. - if (pd->f) eina_file_close(pd->f); - pd->f = tmp; - eina_stringshare_replace(&pd->key, key); - - return EINA_TRUE; -} - -static void -_evas_vg_efl_file_mmap_get(Eo *obj EINA_UNUSED, Evas_VG_Data *pd, - const Eina_File **f, const char **key) -{ - if (f) *f = pd->f; - if (key) *key = pd->key; -} - -Eina_Bool -_evas_vg_efl_file_file_set(Eo *obj, Evas_VG_Data *pd EINA_UNUSED, - const char *file, const char *key) -{ - Eina_File *f; - Eina_Bool r = EINA_FALSE; - - f = eina_file_open(file, EINA_FALSE); - if (!f) return EINA_FALSE; - - eo_do(obj, efl_file_mmap_set(f, key)); - - eina_file_close(f); - return r; -} - -void -_evas_vg_efl_file_file_get(Eo *obj, Evas_VG_Data *pd EINA_UNUSED, - const char **file, const char **key) -{ - const Eina_File *f = NULL; - - eo_do(obj, efl_file_mmap_get(&f, key)); - - if (file) *file = eina_file_filename_get(f); -} - void _evas_vg_efl_gfx_view_size_get(Eo *obj EINA_UNUSED, Evas_VG_Data *pd, int *w, int *h) diff --git a/src/lib/evas/canvas/evas_vg.eo b/src/lib/evas/canvas/evas_vg.eo index 8247f46..8c6d352 100644 --- a/src/lib/evas/canvas/evas_vg.eo +++ b/src/lib/evas/canvas/evas_vg.eo @@ -1,4 +1,4 @@ -class Evas.VG (Evas.Object, Efl.File, Efl.Gfx.Fill, Efl.Gfx.View) +class Evas.VG (Evas.Object, Efl.Gfx.Fill, Efl.Gfx.View) { legacy_prefix: evas_object_vg; eo_prefix: evas_obj_vg; @@ -22,10 +22,6 @@ class Evas.VG (Evas.Object, Efl.File, Efl.Gfx.Fill, Efl.Gfx.View) implements { Eo.Base.constructor; Eo.Base.destructor; - Efl.File.file.set; - Efl.File.file.get; - Efl.File.mmap.set; - Efl.File.mmap.get; Efl.Gfx.Fill.fill.set; Efl.Gfx.Fill.fill.get; Efl.Gfx.View.size.set;