Autocomp: bring the selected item in candidates list.

Summary:
For cases when the autocomplete list contain
a lot of items, that  the list enables scrollbar. This make impossible
to scroll last item by Down arrows. It is happens because the
focus is not allow for elm_list widget. This patch bring
selected item manually.

Reviewers: Hermet

Differential Revision: https://phab.enlightenment.org/D3040
This commit is contained in:
Mykyta Biliavskyi 2015-09-14 14:54:36 +00:00
parent ae2d88fa76
commit 778d3c4879
1 changed files with 5 additions and 1 deletions

View File

@ -749,7 +749,11 @@ list_item_move(autocomp_data *ad, Eina_Bool up)
Elm_Object_Item *it = elm_list_selected_item_get(ad->list);
if (up) it = elm_list_item_prev(it);
else it = elm_list_item_next(it);
if (it) elm_list_item_selected_set(it, EINA_TRUE);
if (it)
{
elm_list_item_selected_set(it, EINA_TRUE);
elm_list_item_bring_in(it);
}
evas_object_smart_callback_add(entry, "unfocused", anchor_unfocused_cb,
ad);