From f4d404d6fda756f6516da80c984b1723d9506137 Mon Sep 17 00:00:00 2001 From: Shinwoo Kim Date: Wed, 24 Oct 2012 02:01:58 +0000 Subject: [PATCH] use existing macro ELM_RECT_INTERSECT(x, y, w, h, xx, yy, ww, hh) to check displayed item. SVN revision: 78380 --- src/lib/elm_genlist.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/lib/elm_genlist.c b/src/lib/elm_genlist.c index 4dac5fa..75d3f04 100644 --- a/src/lib/elm_genlist.c +++ b/src/lib/elm_genlist.c @@ -2388,10 +2388,8 @@ _elm_genlist_smart_focus_next(const Evas_Object *obj, evas_object_geometry_get(it->base.view, &x, &y, &w, &h); /* check item which displays more than half of its size */ - if (((x + (w / 2)) >= sx) && - ((y + (h / 2)) >= sy) && - ((x + (w / 2)) <= (sx + sw)) && - ((y + (h / 2)) <= (sy + sh))) + if (ELM_RECTS_INTERSECT + (x + (w / 2), y + (h / 2), 0, 0, sx, sy, sw, sh)) items = eina_list_append(items, it->base.access_obj); } } -- 2.7.4