genlist : fix crash in banded highlight animator without item banded bg 78/192078/2
authorSangHyeon Jade Lee <sh10233.lee@samsung.com>
Tue, 30 Oct 2018 04:16:54 +0000 (13:16 +0900)
committerSangHyeon Jade Lee <sh10233.lee@samsung.com>
Tue, 30 Oct 2018 04:26:50 +0000 (13:26 +0900)
Change-Id: I8420ed3604f257ca10cf38d32b7d873d8cbefaf2

src/lib/elementary_tizen/elm_genlist.c

index 414fea4..0c3c81a 100644 (file)
@@ -2923,8 +2923,6 @@ _banded_item_highlight_anim(void *data, double pos)
      {
         if (pos < 1.0)
           frame = ecore_animator_pos_map_n(pos, ECORE_POS_MAP_CUBIC_BEZIER, 4, v);
-        else if (pos == 1)
-          it->item->banded_anim = NULL;
 
         if (it->highlighted)
           frame = HIGHLIGHT_ALPHA_MAX + (1.0 - HIGHLIGHT_ALPHA_MAX) * (1.0 - frame);
@@ -2938,6 +2936,8 @@ _banded_item_highlight_anim(void *data, double pos)
         evas_object_color_set(GL_IT(it)->banded_bg, color, color, color, alpha);
      }
 
+   if (EINA_DBL_EQ(pos, 1)) it->item->banded_anim = NULL;
+
    return EINA_TRUE;
 }