devilhorns pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=50ab99b05b2a95c0d52a910f7167309bf1608f13

commit 50ab99b05b2a95c0d52a910f7167309bf1608f13
Author: Chris Michael <[email protected]>
Date:   Wed Nov 21 10:28:51 2018 -0500

    elementary: Reduce EO calls by using geometry_set
    
    This patch reduces EO calls by using evas_object_geometry_set rather
    than calling move & resize.
---
 src/lib/elementary/efl_ui_image_zoomable.c | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/src/lib/elementary/efl_ui_image_zoomable.c 
b/src/lib/elementary/efl_ui_image_zoomable.c
index 1519150c3c..2a565067fd 100644
--- a/src/lib/elementary/efl_ui_image_zoomable.c
+++ b/src/lib/elementary/efl_ui_image_zoomable.c
@@ -198,8 +198,7 @@ _image_place(Evas_Object *obj,
         if (ow > gw) ax = (ow - gw) / 2;
         if (oh > gh) ay = (oh - gh) / 2;
      }
-   evas_object_move(sd->img, ox + 0 - px + ax, oy + 0 - py + ay);
-   evas_object_resize(sd->img, gw, gh);
+   evas_object_geometry_set(sd->img, ox + 0 - px + ax, oy + 0 - py + ay, gw, 
gh);
 
    if (sd->show_item)
      {
@@ -360,10 +359,9 @@ _grid_place(Evas_Object *obj,
                   yy = (gh * yy) / g->h;
                   hh = ((gh * (ty + hh)) / g->h) - yy;
                }
-             evas_object_move(g->grid[tn].img,
-                              ox + xx - px + ax,
-                              oy + yy - py + ay);
-             evas_object_resize(g->grid[tn].img, ww, hh);
+             evas_object_geometry_set(g->grid[tn].img,
+                                      ox + xx - px + ax,
+                                      oy + yy - py + ay, ww, hh);
           }
      }
 }

-- 


Reply via email to