elm/list: avoid erroring on non-elm item contents

putting raw evas and edje objects in here has historically been done,
so handle it without errors

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D11747
This commit is contained in:
Mike Blumenkrantz 2020-04-22 13:13:57 -04:00 committed by Stefan Schmidt
parent 3614c4190d
commit 02ad4d18ba
1 changed files with 10 additions and 4 deletions

View File

@ -2328,18 +2328,24 @@ _item_new(Evas_Object *obj,
evas_object_event_callback_add
(it->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _size_hints_changed_cb,
obj);
if (elm_widget_is(it->icon))
{
efl_access_object_access_type_set(it->icon, EFL_ACCESS_TYPE_DISABLED);
elm_widget_tree_unfocusable_set(it->icon, EINA_TRUE);
}
}
if (it->end)
{
elm_widget_sub_object_add(obj, it->end);
evas_object_event_callback_add
(it->end, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _size_hints_changed_cb,
obj);
if (elm_widget_is(it->end))
{
efl_access_object_access_type_set(it->end, EFL_ACCESS_TYPE_DISABLED);
elm_widget_tree_unfocusable_set(it->end, EINA_TRUE);
}
}
if (_elm_config->atspi_mode)
efl_access_added(eo_it);