summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVaibhav Gupta <g.vaibhav1@samsung.com>2015-08-28 20:03:35 +0900
committerChunEon Park <hermet@hermet.pe.kr>2015-08-28 20:08:12 +0900
commit9a47aa46bdfb844860189a0af3814e26eaa8ed35 (patch)
tree3e6f06a9ae58671a15f65b27222a0bce187f562b
parent9eb86e231e953f63560b2f0fd0a2f6f7b9c93fca (diff)
downloadelementary-9a47aa46bdfb844860189a0af3814e26eaa8ed35.tar.gz
Genlist: Dont select first item if its DISPLAY_ONLY
Summary: Updated genlist to select first item which is not in DISPLAY_ONLY mode @fix Signed-off-by: Vaibhav Gupta <g.vaibhav1@samsung.com> Test Plan: Following is the test to verify: 1. Create a genlist 2. Make 1st item as ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY 3. Now bring the focus to genlist by key down 4. It should bring focus on 2nd item and not 1st. Reviewers: raster, Hermet, SanghyeonLee, singh.amitesh Subscribers: sachin.dev Differential Revision: https://phab.enlightenment.org/D2957
-rw-r--r--src/lib/elm_genlist.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/elm_genlist.c b/src/lib/elm_genlist.c
index 97e557672..48f5554c7 100644
--- a/src/lib/elm_genlist.c
+++ b/src/lib/elm_genlist.c
@@ -3200,6 +3200,14 @@ _elm_genlist_elm_widget_on_focus(Eo *obj, Elm_Genlist_Data *sd)
eo_it = elm_genlist_first_item_get(obj);
is_sel = EINA_TRUE;
}
+
+ while (eo_it)
+ {
+ ELM_GENLIST_ITEM_DATA_GET(eo_it, it);
+ if ((!_is_no_select(it)) && (!elm_object_item_disabled_get(eo_it)))
+ break;
+ eo_it = EO_OBJ(ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->next));
+ }
if (eo_it)
{