}
else
{
- // if item is realized check if in viewport
- if (VIEW(it))
- {
- Evas_Coord wy, wh, y, h;
- evas_object_geometry_get(WIDGET(it), NULL, &wy, NULL, &wh);
- evas_object_geometry_get(VIEW(it), NULL, &y, NULL, &h);
- //TIZEN_ONLY(20161104) : Accessibility : synchronized highlight of atspi and item align feature for wearable profile
- elm_genlist_item_bring_in(eo_it, ELM_GENLIST_ITEM_SCROLLTO_MIDDLE);
- //
+ // TIZEN_ONLY(20171011) : atspi : Do not center align when genlist item is highlighted in wearable profile
+ //FIXME : First, last item is called centered because it may not have a proxy image.
+ // This part will be revised in the next version.
+ Eina_List *realized = elm_genlist_realized_items_get(WIDGET(it));
+ if (VIEW(it) || realized)
+ {
+ Elm_Object_Item *first_it = elm_genlist_first_item_get(WIDGET(it));
+ Elm_Object_Item *last_it = elm_genlist_last_item_get(WIDGET(it));
+ if (first_it == eo_it || last_it == eo_it)
+ elm_genlist_item_bring_in(eo_it, ELM_GENLIST_ITEM_SCROLLTO_MIDDLE);
+ else
+ elm_genlist_item_bring_in(eo_it, ELM_GENLIST_ITEM_SCROLLTO_IN);
}
- else // if item is not realized we should search if we are over or below viewport
- {
- Eina_List *realized = elm_genlist_realized_items_get(WIDGET(it));
- if (realized)
- {
- elm_genlist_item_bring_in(eo_it, ELM_GENLIST_ITEM_SCROLLTO_MIDDLE);
- eina_list_free(realized);
- }
- }
+ if (realized)
+ eina_list_free(realized);
+ //
+
if (VIEW(it))
elm_object_accessibility_highlight_set(EO_OBJ(it), EINA_TRUE);
///TIZEN_ONLY(20170717) : expose highlight information on atspi