elementary: Reduce EO calls by using geometry_set

This patch reduces EO calls by using evas_object_geometry_set rather
than calling move & resize.
This commit is contained in:
Chris Michael 2018-11-21 11:06:51 -05:00
parent e2862ef2e2
commit 9c814cb652
1 changed files with 4 additions and 7 deletions

View File

@ -440,8 +440,7 @@ _obj_place(Evas_Object *obj,
{ {
EINA_SAFETY_ON_NULL_RETURN(obj); EINA_SAFETY_ON_NULL_RETURN(obj);
evas_object_move(obj, x, y); evas_object_geometry_set(obj, x, y, w, h);
evas_object_resize(obj, w, h);
evas_object_show(obj); evas_object_show(obj);
} }
@ -1009,9 +1008,8 @@ _track_place(Elm_Map_Data *sd)
(ymin > py + oh && ymax > py + oh)) (ymin > py + oh && ymax > py + oh))
{ {
//display the route //display the route
evas_object_move(route, xmin - px, ymin - py); evas_object_geometry_set(route, xmin - px, ymin - py,
evas_object_resize(route, xmax - xmin, ymax - ymin); xmax - xmin, ymax - ymin);
evas_object_raise(route); evas_object_raise(route);
_obj_rotate(sd, route); _obj_rotate(sd, route);
evas_object_show(route); evas_object_show(route);
@ -1882,8 +1880,7 @@ _overlay_class_icon_update(Overlay_Class *ovl,
evas_object_del(ovl->icon); evas_object_del(ovl->icon);
ovl->icon = icon; ovl->icon = icon;
// For using proxy, it should have size and be shown but moved away to hide. // For using proxy, it should have size and be shown but moved away to hide.
evas_object_resize(icon, 32, 32); evas_object_geometry_set(icon, -9999, -9999, 32, 32);
evas_object_move(icon, -9999, -9999);
evas_object_show(icon); evas_object_show(icon);
// Update class members' class icons // Update class members' class icons