jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3103c551f5e7622e47c4f4ea27a9012f86b8f127

commit 3103c551f5e7622e47c4f4ea27a9012f86b8f127
Author: Jean-Philippe Andre <[email protected]>
Date:   Tue Mar 14 14:06:24 2017 +0900

    edje: Move prev_description out of ephysics ifdef
    
    prev_description was used when HAVE_EPHYSICS is set, which is the
    default, but I also added a use in 7072fbc2bfe25881 where the map
    was not properly reset.
    
    This removes an ugly #ifdef and opens the door to other fixes
    similar to that map one.
---
 src/lib/edje/edje_calc.c    | 3 +--
 src/lib/edje/edje_private.h | 2 +-
 src/lib/edje/edje_util.c    | 6 +-----
 3 files changed, 3 insertions(+), 8 deletions(-)

diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index 5bb2fbb..6f5e08c 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -5450,8 +5450,8 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int 
flags, Edje_Calc_Params *sta
 
    if (map_colors_free) _map_colors_free(pf);
 
-#ifdef HAVE_EPHYSICS
    ep->prev_description = chosen_desc;
+#ifdef HAVE_EPHYSICS
    if (!ep->body)
      {
 #endif
@@ -5461,7 +5461,6 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int 
flags, Edje_Calc_Params *sta
         ep->h = pf->final.h;
 #ifdef HAVE_EPHYSICS
      }
-
 #endif
 
    ep->calculated |= flags;
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index 11243a5..a849f30 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -2009,8 +2009,8 @@ struct _Edje_Real_Part
    // WITH EDJE_CALC_CACHE: 307
    Edje_Running_Program     *program; // 4
    Edje_Calc_Params         *current; // 4
-#ifdef HAVE_EPHYSICS
    Edje_Part_Description_Common *prev_description; // 4
+#ifdef HAVE_EPHYSICS
    EPhysics_Body            *body; // 4
    Eina_List                *body_faces; // 4
 #endif
diff --git a/src/lib/edje/edje_util.c b/src/lib/edje/edje_util.c
index 3ea970c..b819cc2 100644
--- a/src/lib/edje/edje_util.c
+++ b/src/lib/edje/edje_util.c
@@ -6280,11 +6280,7 @@ _edje_real_part_swallow_clear(Edje *ed, Edje_Real_Part 
*rp)
        (!rp->typedata.swallow)) return;
    if (!rp->typedata.swallow->swallowed_object) return;
    if (rp->chosen_description->map.on ||
-       (rp->invalidate
-#ifdef HAVE_EPHYSICS
-        && rp->prev_description && rp->prev_description->map.on
-#endif
-        ))
+       (rp->invalidate && rp->prev_description && 
rp->prev_description->map.on))
      {
         evas_object_map_enable_set(rp->typedata.swallow->swallowed_object, 
EINA_FALSE);
      }

-- 


Reply via email to