From: Yeongjong Lee Date: Fri, 11 Sep 2020 08:21:19 +0000 (+0900) Subject: ui_widget: restore hide callback for sub-object X-Git-Tag: accepted/tizen/unified/20200914.131356^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F37%2F243937%2F1;p=platform%2Fupstream%2Fefl.git ui_widget: restore hide callback for sub-object In commit 8d47ced0497c7d24203a16c5011c57928822024e, hide callback to restore focus was removed. this patch restores the hide callback to fix focus issue when hiding a focused widgets. @tizen_fix Change-Id: I07cd3bcc329316a03a6e418141c11403a7d49d0d --- diff --git a/src/lib/elementary/efl_ui_widget.c b/src/lib/elementary/efl_ui_widget.c index 61b177b..32e9353 100644 --- a/src/lib/elementary/efl_ui_widget.c +++ b/src/lib/elementary/efl_ui_widget.c @@ -1712,6 +1712,11 @@ _efl_ui_widget_widget_sub_object_add(Eo *obj, Elm_Widget_Smart_Data *sd, Evas_Ob //first add it to our own children list _widget_add_sub(obj, sd, sobj); + //TIZEN_ONLY(20200911): restore hide callback for sub-object + if (is_widget) + efl_event_callback_add(sobj, EFL_GFX_ENTITY_EVENT_VISIBILITY_CHANGED, _on_sub_obj_hide, obj); + // + //and if it is a widget, please set the correct parent on the widget itself //the parent set method will take care of the property syncing etc. if (is_widget) @@ -1861,6 +1866,11 @@ _efl_ui_widget_widget_sub_object_del(Eo *obj, Elm_Widget_Smart_Data *sd, Evas_Ob _widget_del_sub(obj, sd, sobj); + //TIZEN_ONLY(20200911): restore hide callback for sub-object + if (is_widget) + efl_event_callback_del(sobj, EFL_GFX_ENTITY_EVENT_VISIBILITY_CHANGED, _on_sub_obj_hide, obj); + // + return EINA_TRUE; }