From 90024102fd73a17e8e52f715a41308460374013f Mon Sep 17 00:00:00 2001 From: Daniel Juyung Seo Date: Thu, 20 Mar 2014 04:04:12 +0900 Subject: [PATCH] elm_widget: Call widget APIs only for widgets. 'cur' object can be non-widget object when calling elm_widget_focus_direction_get and elm_widget_parent_get. --- legacy/elementary/src/lib/elm_widget.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/legacy/elementary/src/lib/elm_widget.c b/legacy/elementary/src/lib/elm_widget.c index 3c1e0a4ab3..25f17863b7 100644 --- a/legacy/elementary/src/lib/elm_widget.c +++ b/legacy/elementary/src/lib/elm_widget.c @@ -2155,7 +2155,7 @@ _elm_widget_focus_list_direction_get(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data for (; l; l = eina_list_next(l)) { Evas_Object *cur = list_data_get(l); - if (cur) + if (cur && _elm_widget_is(cur)) elm_widget_focus_direction_get(cur, base, degree, direction, weight); } if (current_best != *direction) return EINA_TRUE; @@ -2380,6 +2380,7 @@ _elm_widget_focus_list_next_get(Eo *obj, Elm_Widget_Smart_Data *_pd EINA_UNUSED, Evas_Object *cur = list_data_get(l); if (!cur) continue; + if (!_elm_widget_is(cur)) continue; if (elm_widget_parent_get(cur) != obj) continue;