From f6b7012329f23c2cecb5c73fbe92135283c900ac Mon Sep 17 00:00:00 2001 From: efl Date: Wed, 11 Jun 2014 14:07:01 +0900 Subject: [PATCH] List: Focus set on item content objects, the item content objects should be checked whether type widget or not. Summary: Upon focus set, if the item content object is not of type widget (could be of type Evas_Rectnagle) focus set/get is not possible. ERR<17428>:eo lib/eo/eo.c:603 _eo_call_resolve() in elm_widget.eo.c:112: you called func 'elm_obj_widget_can_focus_get' (239) which is unknown in class 'Evas_Rectangle'. ERR<17428>:eo lib/eo/eo.c:788 _eo_api_op_id_get() in elm_widget.eo.c:212: unable to resolve regular api func 'elm_obj_widget_child_can_focus_get' 0xb75e6f40 in class 'Evas_Rectangle' Test Plan: elementary_test -to "list focus" (make focus_on_selection enabled and give a right key event when a content object is focused) Reviewers: seoz, SanghyeonLee, eagleeye CC: seoz Differential Revision: https://phab.enlightenment.org/D972 --- legacy/elementary/src/lib/elm_list.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/legacy/elementary/src/lib/elm_list.c b/legacy/elementary/src/lib/elm_list.c index cbf69b2..e6c94df 100644 --- a/legacy/elementary/src/lib/elm_list.c +++ b/legacy/elementary/src/lib/elm_list.c @@ -249,10 +249,10 @@ _elm_list_item_content_focus_set(Elm_List_Item *it, Elm_Focus_Direction dir, Evas_Object *focus_chain[2]; Evas_Object *focused = NULL; int idx; - - if (it->icon && elm_object_focus_allow_get(it->icon)) + + if (it->icon && elm_object_widget_check(it->icon) && elm_object_focus_allow_get(it->icon)) focus_chain[focus_objs++] = it->icon; - if (it->end && elm_object_focus_allow_get(it->end)) + if (it->end && elm_object_widget_check(it->end) && elm_object_focus_allow_get(it->end)) focus_chain[focus_objs++] = it->end; if (!focus_objs) -- 2.7.4