From: SangHyeon Lee Date: Wed, 25 Jan 2017 05:33:38 +0000 (+0900) Subject: gengrid: fix mirrored position calculate to apply pan width instead of object width X-Git-Tag: submit/tizen/20170221.045909~19 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=46ef9a9157d2e1348fdee66ba264c0836a69b1af;p=platform%2Fupstream%2Felementary.git gengrid: fix mirrored position calculate to apply pan width instead of object width This is port of upstream patch bec54fc870e813ac5d091d34e2374ba01861a877 Change-Id: Ic9979a9c79facf3545047dd6d0f88c91da930336 Signed-off-by: SangHyeon Lee --- diff --git a/src/lib/elm_gengrid.c b/src/lib/elm_gengrid.c index 9d76dafc6..d4af13d1d 100644 --- a/src/lib/elm_gengrid.c +++ b/src/lib/elm_gengrid.c @@ -1763,7 +1763,7 @@ _item_place(Elm_Gen_Item *it, Evas_Coord cx, Evas_Coord cy) { - Evas_Coord x, y, ox, oy, cvx, cvy, cvw, cvh, iw, ih, ww; + Evas_Coord x, y, ox, oy, cvx, cvy, cvw, cvh, iw, ih; Evas_Coord tch, tcw, alignw = 0, alignh = 0, vw, vh; Eina_Bool reorder_item_move_forward = EINA_FALSE; Eina_Bool was_realized, can_resize; @@ -1941,11 +1941,10 @@ _item_place(Elm_Gen_Item *it, * pan_x when in RTL * mode */ { - evas_object_geometry_get(WIDGET(it), NULL, NULL, &ww, NULL); if (wsd->horizontal && can_resize) - x = ww - x - it->item->w - wsd->pan_x - wsd->pan_x + ox + ox; + x = vw - x - it->item->w - wsd->pan_x - wsd->pan_x + ox + ox; else - x = ww - x - wsd->item_width - wsd->pan_x - wsd->pan_x + ox + ox; + x = vw - x - wsd->item_width - wsd->pan_x - wsd->pan_x + ox + ox; } iw = (wsd->horizontal && can_resize) ? it->item->w : wsd->item_width; ih = (!wsd->horizontal && can_resize) ? it->item->h : wsd->item_height;