From d76657257e209cd2ee23007dffbef35663e8c4a6 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Mon, 25 Mar 2019 19:46:24 +0900 Subject: [PATCH] efl_ui_image: remove job in sizing calc. Originally, this job task was introduced for trick optimization to avoid unnecessary duplicated compuation. But this introduced a regression bug as well, image geometry updation was delayed by this. So, we remove the job here. @fix T7360 Change-Id: I6a11744777186b486e81b87ea5293fa564c732ed --- src/lib/elementary/efl_ui_image.c | 26 ++++---------------------- src/lib/elementary/efl_ui_widget_image.h | 2 -- 2 files changed, 4 insertions(+), 24 deletions(-) diff --git a/src/lib/elementary/efl_ui_image.c b/src/lib/elementary/efl_ui_image.c index b11eb1a..f333dbc 100644 --- a/src/lib/elementary/efl_ui_image.c +++ b/src/lib/elementary/efl_ui_image.c @@ -603,7 +603,6 @@ _efl_ui_image_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Image_Data *sd) if (elm_widget_is_legacy(obj)) efl_event_callback_del(obj, EFL_GFX_ENTITY_EVENT_HINTS_CHANGED, _on_size_hints_changed, sd); - ecore_job_del(sd->sizing_job); ecore_timer_del(sd->anim_timer); evas_object_del(sd->img); _prev_img_del(sd); @@ -744,18 +743,15 @@ _key_action_activate(Evas_Object *obj, const char *params EINA_UNUSED) return EINA_TRUE; } -static void -_sizing_eval_cb(void *data) +void +_efl_ui_image_sizing_eval(Evas_Object *obj) { - Evas_Object *obj = data; + EFL_UI_IMAGE_DATA_GET_OR_RETURN(obj, sd); + Evas_Coord minw = -1, minh = -1, maxw = -1, maxh = -1; Eina_Size2D sz; double ts; - EFL_UI_IMAGE_DATA_GET_OR_RETURN(obj, sd); - - sd->sizing_job = NULL; - // TODO: remove this function after using the widget's scale value instead of image's scale value, if (sd->no_scale) sd->scale = 1.0; @@ -824,20 +820,6 @@ _sizing_eval_cb(void *data) } } -void -_efl_ui_image_sizing_eval(Evas_Object *obj) -{ - EFL_UI_IMAGE_DATA_GET_OR_RETURN(obj, sd); - - //TIZEN_ONLY(20181001): remove ecore job temporarily. - _sizing_eval_cb(obj); - /* - if (sd->sizing_job) ecore_job_del(sd->sizing_job); - sd->sizing_job = ecore_job_add(_sizing_eval_cb, obj); - */ - // -} - static void _efl_ui_image_load_size_set_internal(Evas_Object *obj, Efl_Ui_Image_Data *sd) { diff --git a/src/lib/elementary/efl_ui_widget_image.h b/src/lib/elementary/efl_ui_widget_image.h index 004222e..8a5beef 100644 --- a/src/lib/elementary/efl_ui_widget_image.h +++ b/src/lib/elementary/efl_ui_widget_image.h @@ -92,8 +92,6 @@ struct _Efl_Ui_Image_Data Eina_Bool use : 1; } freedesktop; - Ecore_Job *sizing_job; - Eina_Bool aspect_fixed : 1; Eina_Bool fill_inside : 1; Eina_Bool no_scale : 1; -- 2.7.4