summaryrefslogtreecommitdiff
path: root/src/lib/edje/edje_calc.c
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-02-21 17:49:44 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-02-21 17:56:31 +0900
commit882ad6fbf5df6bbfe4a224fafc98992b37dbc668 (patch)
tree18394dd3af2499ca1da84016f266feb6bbdc0cd7 /src/lib/edje/edje_calc.c
parent81fbd54c17e84514d3f74a795b2a6db189df9533 (diff)
edje: Fix a major issue with recalc loop
With the new Efl.Ui.Clock widget, which implements Datetime, most parts are relative to each other, and trigger a near-inifinite recalc of all the parts. Indeed edje was recalculating a part even if it had already calculated it (flag is set). This seemingly simple patch fixes Datetime and probably a lot of other edje widgets. Fixes T4909 @fix
Diffstat (limited to 'src/lib/edje/edje_calc.c')
-rw-r--r--src/lib/edje/edje_calc.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index d52069d85c..5bb2fbb50a 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -4244,10 +4244,13 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags, Edje_Calc_Params *sta
4244 return; 4244 return;
4245 } 4245 }
4246 4246
4247 if ((ep->calculated & FLAG_XY) == FLAG_XY && !state) 4247 EINA_SAFETY_ON_FALSE_RETURN(flags != FLAG_NONE);
4248 if (!state)
4248 { 4249 {
4249 return; 4250 if ((ep->calculated & FLAG_XY) == FLAG_XY) return;
4251 if ((ep->calculated & flags) == flags) return;
4250 } 4252 }
4253
4251 if (ep->calculating & flags) 4254 if (ep->calculating & flags)
4252 { 4255 {
4253#if 1 4256#if 1