From: Anil Kumar Nahak Date: Thu, 3 Jul 2014 07:39:41 +0000 (+0900) Subject: genlist: focus of genlist item should adjust according to genlist's viewport X-Git-Tag: upstream/1.20.0~7116^2~14^2~2373 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2b8e6862ac103093fd064d4b17b15ce2ee4bf593;p=platform%2Fupstream%2Fefl.git genlist: focus of genlist item should adjust according to genlist's viewport Summary: The focus of genlist should adjust its position on resizing(shrinking). Reviewers: seoz Differential Revision: https://phab.enlightenment.org/D1072 --- diff --git a/legacy/elementary/src/lib/elm_genlist.c b/legacy/elementary/src/lib/elm_genlist.c index 2d2d1ec..49535eb 100644 --- a/legacy/elementary/src/lib/elm_genlist.c +++ b/legacy/elementary/src/lib/elm_genlist.c @@ -7487,7 +7487,7 @@ _elm_genlist_elm_widget_focus_highlight_geometry_get(Eo *obj EINA_UNUSED, Elm_Ge { *y = oy; } - else if (item_y > (oy + oh - item_h)) + if (item_y > (oy + oh - item_h)) { *y = oy + oh - item_h; } @@ -7496,6 +7496,10 @@ _elm_genlist_elm_widget_focus_highlight_geometry_get(Eo *obj EINA_UNUSED, Elm_Ge { *w = item_w - (item_w - ow); } + if (item_x < ox) + { + *x = ox; + } } EOLIAN static Elm_Object_Item *