From 4ebbe0ad0444f31a6c58ec37e9fcdf6dde31fd8b Mon Sep 17 00:00:00 2001 From: Woochanlee Date: Tue, 26 Nov 2019 13:57:16 +0900 Subject: edje_calc: Creation macro that perform edje calc, regardless of the edje size. Summary: edje_recalc_do() needs to be executed regardless of the size of edje in order to deliver edje properties for the API that the user calls. Reviewers: cedric, Hermet, Jaehyun_Cho, smohanty Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D10724 --- src/lib/edje/edje_calc.c | 33 ++------------------------------- 1 file changed, 2 insertions(+), 31 deletions(-) (limited to 'src/lib/edje/edje_calc.c') diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c index 5e1ce0bcae..cadadb5f72 100644 --- a/src/lib/edje/edje_calc.c +++ b/src/lib/edje/edje_calc.c @@ -1003,30 +1003,6 @@ _edje_recalc_table_parts(Edje *ed #endif } -// Defined in edje_textblock.c -Eina_Bool -_edje_part_textblock_style_text_set(Edje *ed, - Edje_Real_Part *ep, - Edje_Part_Description_Text *chosen_desc); - -void -_edje_recalc_textblock_style_text_set(Edje *ed) -{ - unsigned short i; - Edje_Real_Part *ep; - - for (i = 0; i < ed->table_parts_size; i++) - { - ep = ed->table_parts[i]; - - if (ep->part->type == EDJE_PART_TYPE_TEXTBLOCK) - { - _edje_part_textblock_style_text_set - (ed, ep, (Edje_Part_Description_Text *)ep->chosen_description); - } - } -} - void _edje_recalc_do(Edje *ed) { @@ -1037,14 +1013,9 @@ _edje_recalc_do(Edje *ed) #endif - //Do nothing if the edje has no size, Regardless of the edje part size calc, - //the text and style has to be set. + //Do nothing if the edje has no size, if ((EINA_UNLIKELY(!ed->has_size)) && (!ed->calc_only) && (ed->w == 0) && (ed->h == 0)) - { - _edje_recalc_textblock_style_text_set(ed); - - return; - } + return; ed->has_size = EINA_TRUE; need_calc = evas_object_smart_need_recalculate_get(ed->obj); -- cgit v1.2.1