From c3cc96d0f8f592c75c4c62031d69c95c82b32f18 Mon Sep 17 00:00:00 2001 From: Marcel Hollerbach Date: Mon, 23 Mar 2020 12:12:19 -0400 Subject: [PATCH] efl_ui_widget: do not eval all the children twice Summary: eval all children is ending up in the complete discovery of the whole subtree, which is unnessesary here, as we are already discovering the whole subtree with the calls, these changes are in, so simple evalulating this is enough. Depends on D11551 Reviewers: zmike Reviewed By: zmike Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11554 --- src/lib/elementary/efl_ui_widget.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/lib/elementary/efl_ui_widget.c b/src/lib/elementary/efl_ui_widget.c index f5063a3575..5cd1df091f 100644 --- a/src/lib/elementary/efl_ui_widget.c +++ b/src/lib/elementary/efl_ui_widget.c @@ -1766,15 +1766,13 @@ elm_widget_tree_unfocusable_set(Eo *obj, Eina_Bool tree_unfocusable) } if (old_tree_unfocusable != pd->tree_unfocusable) { + _full_eval(obj, pd); for (unsigned int i = 0; i < eina_array_count(pd->children); ++i) { subs = eina_array_data_get(pd->children, i); if (efl_isa(subs, EFL_UI_WIDGET_CLASS)) elm_widget_tree_unfocusable_set(subs, elm_widget_tree_unfocusable_get(obj)); } - - //focus state eval on all children - _elm_widget_full_eval_children(obj, pd); } } @@ -2129,14 +2127,14 @@ _efl_ui_widget_disabled_set(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *pd, Eina } if (old_state != pd->disabled) { + if (efl_finalized_get(obj)) + _full_eval(obj, pd); for (unsigned int i = 0; i < eina_array_count(pd->children); ++i) { subs = eina_array_data_get(pd->children, i); if (efl_isa(subs, EFL_UI_WIDGET_CLASS)) efl_ui_widget_disabled_set(subs, efl_ui_widget_disabled_get(obj)); } - if (efl_finalized_get(obj)) - _elm_widget_full_eval_children(obj, pd); } }