From 3191e74b08cc37deca147134f32f81de1b2928c3 Mon Sep 17 00:00:00 2001 From: Wonki Kim Date: Mon, 22 Jul 2019 09:08:55 -0400 Subject: [PATCH] efl_ui_layout: set needs_size_calc flag at constructor Summary: even if there is a min definition on theme for some object, the objects don't have the min size if we do nothing after creating it. elm_layout_sizing_eval will return with doing nothing while executing contructor so that _sizing_eval in _layout_group_calculate will never be invoked without calling hint_set, text_set, content_set, etc. this patch modifies a initial state of needs_size_calc flag so that object will doing _sizing_eval after executing constructor. Test Plan: 1. remove lines that call apis such as content_set, hint_set, text_set in radio test on elementary_test 2. observe that radios don't have min size Reviewers: bu5hm4n, Hermet, zmike Reviewed By: zmike Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9368 --- src/lib/elementary/efl_ui_layout.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/elementary/efl_ui_layout.c b/src/lib/elementary/efl_ui_layout.c index cef9286..98cc674 100644 --- a/src/lib/elementary/efl_ui_layout.c +++ b/src/lib/elementary/efl_ui_layout.c @@ -2663,7 +2663,7 @@ _efl_ui_layout_base_efl_object_constructor(Eo *obj, Efl_Ui_Layout_Data *sd) } EOLIAN static Efl_Object* -_efl_ui_layout_base_efl_object_finalize(Eo *obj, Efl_Ui_Layout_Data *pd EINA_UNUSED) +_efl_ui_layout_base_efl_object_finalize(Eo *obj, Efl_Ui_Layout_Data *pd) { Eo *eo, *win; ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL); @@ -2677,6 +2677,8 @@ _efl_ui_layout_base_efl_object_finalize(Eo *obj, Efl_Ui_Layout_Data *pd EINA_UNU if (efl_file_get(wd->resize_obj) || efl_file_mmap_get(wd->resize_obj)) efl_file_load(wd->resize_obj); + pd->needs_size_calc = EINA_TRUE; + return eo; } -- 2.7.4