summaryrefslogtreecommitdiff
path: root/src/lib/elementary/efl_ui_grid_static.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/elementary/efl_ui_grid_static.c')
-rw-r--r--src/lib/elementary/efl_ui_grid_static.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/src/lib/elementary/efl_ui_grid_static.c b/src/lib/elementary/efl_ui_grid_static.c
index dfa128a..fb5601a 100644
--- a/src/lib/elementary/efl_ui_grid_static.c
+++ b/src/lib/elementary/efl_ui_grid_static.c
@@ -26,9 +26,9 @@ _efl_ui_grid_static_efl_pack_layout_layout_update(Eo *obj, void *_pd EINA_UNUSED
26 Efl_Ui_Grid_Data *gd; 26 Efl_Ui_Grid_Data *gd;
27 Grid_Item *gi; 27 Grid_Item *gi;
28 Evas *e; 28 Evas *e;
29 Evas_Coord x, y, w, h;
30 long long xl, yl, wl, hl, vwl, vhl; 29 long long xl, yl, wl, hl, vwl, vhl;
31 Eina_Bool mirror; 30 Eina_Bool mirror;
31 Eina_Rect r;
32 32
33 gd = efl_data_scope_get(obj, EFL_UI_GRID_CLASS); 33 gd = efl_data_scope_get(obj, EFL_UI_GRID_CLASS);
34 if (!gd->items) return; 34 if (!gd->items) return;
@@ -36,12 +36,11 @@ _efl_ui_grid_static_efl_pack_layout_layout_update(Eo *obj, void *_pd EINA_UNUSED
36 e = evas_object_evas_get(obj); 36 e = evas_object_evas_get(obj);
37 efl_event_freeze(e); 37 efl_event_freeze(e);
38 38
39 efl_gfx_position_get(obj, &x, &y); 39 r = efl_gfx_geometry_get(obj);
40 efl_gfx_size_get(obj, &w, &h); 40 xl = r.x;
41 xl = x; 41 yl = r.y;
42 yl = y; 42 wl = r.w;
43 wl = w; 43 hl = r.h;
44 hl = h;
45 mirror = efl_ui_mirrored_get(obj); 44 mirror = efl_ui_mirrored_get(obj);
46 45
47 if (!gd->req_cols || !gd->req_rows) 46 if (!gd->req_cols || !gd->req_rows)
@@ -69,8 +68,7 @@ _efl_ui_grid_static_efl_pack_layout_layout_update(Eo *obj, void *_pd EINA_UNUSED
69 } 68 }
70 y1 = yl + ((hl * (long long)gi->row) / vhl); 69 y1 = yl + ((hl * (long long)gi->row) / vhl);
71 y2 = yl + ((hl * (long long)(gi->row + gi->row_span)) / vhl); 70 y2 = yl + ((hl * (long long)(gi->row + gi->row_span)) / vhl);
72 efl_gfx_position_set(gi->object, x1, y1); 71 efl_gfx_geometry_set(gi->object, EINA_RECT(x1, y1, x2 - x1, y2 - y1));
73 efl_gfx_size_set(gi->object, x2 - x1, y2 - y1);
74 } 72 }
75err: 73err:
76 efl_event_thaw(e); 74 efl_event_thaw(e);