summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTaehyub Kim <taehyub.kim@samsung.com>2017-09-19 09:36:26 +0900
committerJaehyun Cho <jae_hyun.cho@samsung.com>2017-11-28 17:15:42 +0900
commitf5010b7ba6d63cb665e8045b4e4ad1d8a85d7ad1 (patch)
tree04722609b58ca14d92793596161418b431e7f00f
parent2e9042fae130ce9e6f7706b72c3d217cd506733a (diff)
efl_ui_popup_alert_scroll: check sizing evaluation while scroller is changed
Summary: add a sizing check variable for safety of sizing evaluation when the min size of scroller is changed. Test Plan: 1. run elementary_test 2. search the sample with "popup" keyword 3. click the Efl Ui Popup Alert Scroll sample Reviewers: Jaehyun_Cho, jpeg, woohyun, thiepha, Blackmole, cedric Reviewed By: Jaehyun_Cho Differential Revision: https://phab.enlightenment.org/D5204
-rw-r--r--src/lib/elementary/efl_ui_popup_alert_scroll.c6
-rw-r--r--src/lib/elementary/efl_ui_popup_alert_scroll_private.h1
2 files changed, 7 insertions, 0 deletions
diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll.c b/src/lib/elementary/efl_ui_popup_alert_scroll.c
index ca0fe76..290fc0f 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll.c
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll.c
@@ -18,6 +18,8 @@ _scroller_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data *pd, Evas_Coord mi
18 Evas_Coord w, h; 18 Evas_Coord w, h;
19 evas_object_geometry_get(obj, NULL, NULL, &w, &h); 19 evas_object_geometry_get(obj, NULL, NULL, &w, &h);
20 20
21 pd->is_sizing_eval = EINA_TRUE;
22
21 if (pd->is_expandable_w && !pd->is_expandable_h) 23 if (pd->is_expandable_w && !pd->is_expandable_h)
22 { 24 {
23 if ((pd->max_scroll_w > -1) && (minw > pd->max_scroll_w)) 25 if ((pd->max_scroll_w > -1) && (minw > pd->max_scroll_w))
@@ -59,11 +61,15 @@ _scroller_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data *pd, Evas_Coord mi
59 evas_object_resize(obj, pd->max_scroll_w, pd->max_scroll_h); 61 evas_object_resize(obj, pd->max_scroll_w, pd->max_scroll_h);
60 } 62 }
61 } 63 }
64
65 pd->is_sizing_eval = EINA_FALSE;
62} 66}
63 67
64EOLIAN static void 68EOLIAN static void
65_efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data *pd) 69_efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data *pd)
66{ 70{
71 if (pd->is_sizing_eval) return;
72
67 elm_layout_sizing_eval(efl_super(obj, MY_CLASS)); 73 elm_layout_sizing_eval(efl_super(obj, MY_CLASS));
68 74
69 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); 75 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll_private.h b/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
index d72e359..3eb4005 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
@@ -12,6 +12,7 @@ struct _Efl_Ui_Popup_Alert_Scroll_Data
12 Evas_Coord max_scroll_h; 12 Evas_Coord max_scroll_h;
13 Eina_Bool is_expandable_w; 13 Eina_Bool is_expandable_w;
14 Eina_Bool is_expandable_h; 14 Eina_Bool is_expandable_h;
15 Eina_Bool is_sizing_eval;
15}; 16};
16 17
17#endif 18#endif