From c6d6e130601567cc503ebab5cc9ded288536bbc1 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Andre Date: Fri, 12 May 2017 12:02:24 +0900 Subject: [PATCH] evas map: Rename raw_coord to coord_absolute This is more in line with the other "absolute" APIs. --- src/bin/elementary/test_flip_page_eo.c | 12 ++++++------ src/examples/evas/evas-map-aa-eo.c | 18 +++++++++--------- src/examples/evas/evas-map-utils-eo.c | 8 ++++---- src/lib/evas/canvas/efl_gfx_map.c | 8 ++++---- src/lib/evas/canvas/efl_gfx_map.eo | 2 +- 5 files changed, 24 insertions(+), 24 deletions(-) diff --git a/src/bin/elementary/test_flip_page_eo.c b/src/bin/elementary/test_flip_page_eo.c index 0722822..cf88d02 100644 --- a/src/bin/elementary/test_flip_page_eo.c +++ b/src/bin/elementary/test_flip_page_eo.c @@ -96,25 +96,25 @@ _slice_apply(State *st, Slice *sl, if (st->dir == 0) { int p[4] = { 0, 1, 2, 3 }; - efl_gfx_map_raw_coord_set(sl->obj, i, ox + sl->x[p[i]], oy + sl->y[p[i]], sl->z[p[i]]); + efl_gfx_map_coord_absolute_set(sl->obj, i, ox + sl->x[p[i]], oy + sl->y[p[i]], sl->z[p[i]]); efl_gfx_map_uv_set(sl->obj, i, sl->u[p[i]] , sl->v[p[i]]); } else if (st->dir == 1) { int p[4] = { 1, 0, 3, 2 }; - efl_gfx_map_raw_coord_set(sl->obj, i, ox + (w - sl->x[p[i]]), oy + sl->y[p[i]], sl->z[p[i]]); + efl_gfx_map_coord_absolute_set(sl->obj, i, ox + (w - sl->x[p[i]]), oy + sl->y[p[i]], sl->z[p[i]]); efl_gfx_map_uv_set(sl->obj, i, 1. - sl->u[p[i]] , sl->v[p[i]]); } else if (st->dir == 2) { int p[4] = { 1, 0, 3, 2 }; - efl_gfx_map_raw_coord_set(sl->obj, i, ox + sl->y[p[i]], oy + sl->x[p[i]], sl->z[p[i]]); + efl_gfx_map_coord_absolute_set(sl->obj, i, ox + sl->y[p[i]], oy + sl->x[p[i]], sl->z[p[i]]); efl_gfx_map_uv_set(sl->obj, i, sl->v[p[i]] , sl->u[p[i]]); } else if (st->dir == 3) { int p[4] = { 0, 1, 2, 3 }; - efl_gfx_map_raw_coord_set(sl->obj, i, ox + sl->y[p[i]], oy + (w - sl->x[p[i]]), sl->z[p[i]]); + efl_gfx_map_coord_absolute_set(sl->obj, i, ox + sl->y[p[i]], oy + (w - sl->x[p[i]]), sl->z[p[i]]); efl_gfx_map_uv_set(sl->obj, i, sl->v[p[i]] , 1. - sl->u[p[i]]); } } @@ -131,8 +131,8 @@ _slice_3d(State *st EINA_UNUSED, Slice *sl, Evas_Coord x, Evas_Coord y, Evas_Coo { double xx, yy; - efl_gfx_map_raw_coord_get(sl->obj, i, &xx, &yy, NULL); - efl_gfx_map_raw_coord_set(sl->obj, i, xx, yy, 0); + efl_gfx_map_coord_absolute_get(sl->obj, i, &xx, &yy, NULL); + efl_gfx_map_coord_absolute_set(sl->obj, i, xx, yy, 0); } efl_gfx_visible_set(sl->obj, efl_gfx_map_clockwise_get(sl->obj)); } diff --git a/src/examples/evas/evas-map-aa-eo.c b/src/examples/evas/evas-map-aa-eo.c index 5b4c66f..3b6b78b 100644 --- a/src/examples/evas/evas-map-aa-eo.c +++ b/src/examples/evas/evas-map-aa-eo.c @@ -60,15 +60,15 @@ static struct exemple_data d = static void update(void) { - efl_gfx_map_raw_coord_set(d.target1, 0, d.px1, d.py1, 0); - efl_gfx_map_raw_coord_set(d.target1, 1, d.px2, d.py2, 0); - efl_gfx_map_raw_coord_set(d.target1, 2, d.px3, d.py3, 0); - efl_gfx_map_raw_coord_set(d.target1, 3, d.px4, d.py4, 0); - - efl_gfx_map_raw_coord_set(d.target2, 0, d.px1 + 400, d.py1, 0); - efl_gfx_map_raw_coord_set(d.target2, 1, d.px2 + 400, d.py2, 0); - efl_gfx_map_raw_coord_set(d.target2, 2, d.px3 + 400, d.py3, 0); - efl_gfx_map_raw_coord_set(d.target2, 3, d.px4 + 400, d.py4, 0); + efl_gfx_map_coord_absolute_set(d.target1, 0, d.px1, d.py1, 0); + efl_gfx_map_coord_absolute_set(d.target1, 1, d.px2, d.py2, 0); + efl_gfx_map_coord_absolute_set(d.target1, 2, d.px3, d.py3, 0); + efl_gfx_map_coord_absolute_set(d.target1, 3, d.px4, d.py4, 0); + + efl_gfx_map_coord_absolute_set(d.target2, 0, d.px1 + 400, d.py1, 0); + efl_gfx_map_coord_absolute_set(d.target2, 1, d.px2 + 400, d.py2, 0); + efl_gfx_map_coord_absolute_set(d.target2, 2, d.px3 + 400, d.py3, 0); + efl_gfx_map_coord_absolute_set(d.target2, 3, d.px4 + 400, d.py4, 0); } static void diff --git a/src/examples/evas/evas-map-utils-eo.c b/src/examples/evas/evas-map-utils-eo.c index fdf000e..6ce5fc0 100644 --- a/src/examples/evas/evas-map-utils-eo.c +++ b/src/examples/evas/evas-map-utils-eo.c @@ -131,10 +131,10 @@ _anim_cb(void *data) efl_gfx_map_reset(o); efl_gfx_map_smooth_set(o, ad->smooth); efl_gfx_map_alpha_set(o, ad->alpha); - efl_gfx_map_raw_coord_set(o, 0, x, y + h, 0); - efl_gfx_map_raw_coord_set(o, 1, x + w, y + h, 0); - efl_gfx_map_raw_coord_set(o, 2, win_w - 10, win_h - 30, 0); - efl_gfx_map_raw_coord_set(o, 3, (win_w / 2) + 10, win_h - 30, 0); + efl_gfx_map_coord_absolute_set(o, 0, x, y + h, 0); + efl_gfx_map_coord_absolute_set(o, 1, x + w, y + h, 0); + efl_gfx_map_coord_absolute_set(o, 2, win_w - 10, win_h - 30, 0); + efl_gfx_map_coord_absolute_set(o, 3, (win_w / 2) + 10, win_h - 30, 0); efl_gfx_map_uv_set(o, 0, 0, 1); efl_gfx_map_uv_set(o, 1, 1, 1); efl_gfx_map_uv_set(o, 2, 1, 2. / 3.); diff --git a/src/lib/evas/canvas/efl_gfx_map.c b/src/lib/evas/canvas/efl_gfx_map.c index bb14b02..63667cc 100644 --- a/src/lib/evas/canvas/efl_gfx_map.c +++ b/src/lib/evas/canvas/efl_gfx_map.c @@ -534,8 +534,8 @@ _efl_gfx_map_map_alpha_get(Eo *eo_obj EINA_UNUSED, Efl_Gfx_Map_Data *pd) } EOLIAN static void -_efl_gfx_map_map_raw_coord_get(Eo *eo_obj, Efl_Gfx_Map_Data *pd, - int idx, double *x, double *y, double *z) +_efl_gfx_map_map_coord_absolute_get(Eo *eo_obj, Efl_Gfx_Map_Data *pd, + int idx, double *x, double *y, double *z) { Evas_Object_Protected_Data *obj = EVAS_OBJ_GET_OR_RETURN(eo_obj); Evas_Map *m; @@ -691,8 +691,8 @@ _gfx_map_op_add(Eo *eo_obj, Efl_Gfx_Map_Data *pd, Gfx_Map_Op_Type type, } EOLIAN static void -_efl_gfx_map_map_raw_coord_set(Eo *eo_obj, Efl_Gfx_Map_Data *pd, - int idx, double x, double y, double z) +_efl_gfx_map_map_coord_absolute_set(Eo *eo_obj, Efl_Gfx_Map_Data *pd, + int idx, double x, double y, double z) { Gfx_Map_Op *op; diff --git a/src/lib/evas/canvas/efl_gfx_map.eo b/src/lib/evas/canvas/efl_gfx_map.eo index 93327cf..39d3445 100644 --- a/src/lib/evas/canvas/efl_gfx_map.eo +++ b/src/lib/evas/canvas/efl_gfx_map.eo @@ -81,7 +81,7 @@ mixin Efl.Gfx.Map (Efl.Interface, Efl.Object) alpha: bool; [[$true by default.]] } } - @property map_raw_coord { + @property map_coord_absolute { [[A point's absolute coordinate on the canvas. This sets/gets the fixed point's coordinate in the map. Note that points -- 2.7.4