eunue pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=690269e055546655988e33203aba255bafac35ff

commit 690269e055546655988e33203aba255bafac35ff
Author: Jaeun Choi <[email protected]>
Date:   Thu Dec 13 17:59:47 2018 +0900

    efl_page_transition_scroll: bug fix in update function
    
    since page_infos are connected in a circular manner,
    one node (head or tail) moves in the opposite direction when scrolled.
    there was a bug in hiding such nodes and
    this patch fixes it.
---
 src/lib/elementary/efl_page_transition_scroll.c | 18 +++++++++++++++---
 1 file changed, 15 insertions(+), 3 deletions(-)

diff --git a/src/lib/elementary/efl_page_transition_scroll.c 
b/src/lib/elementary/efl_page_transition_scroll.c
index 41b70336c3..71b7bfabb2 100644
--- a/src/lib/elementary/efl_page_transition_scroll.c
+++ b/src/lib/elementary/efl_page_transition_scroll.c
@@ -303,7 +303,7 @@ _efl_page_transition_scroll_update(Eo *obj,
    int tmp_id, curr_page, cnt;
    Eo *tmp;
    Eina_List *list;
-   Page_Info *pi, *tpi;
+   Page_Info *pi, *tpi, *dummy;
 
    t = pos;
    if (t < 0) t *= (-1);
@@ -330,8 +330,6 @@ _efl_page_transition_scroll_update(Eo *obj,
 
         efl_gfx_entity_geometry_set(pi->obj, (Eina_Rect) pi->temp);
 
-        if (!pi->vis_page && !tpi->vis_page) continue;
-
         if (!eina_rectangles_intersect(&pi->temp, &pd->viewport))
           {
              if (pi->content)
@@ -379,6 +377,20 @@ _efl_page_transition_scroll_update(Eo *obj,
                }
           }
      }
+
+   if (pos < 0) dummy = pd->tail;
+   else dummy = pd->head;
+
+   if (dummy->visible)
+     {
+        efl_canvas_object_clip_set(dummy->obj, pd->backclip);
+        efl_pack_unpack(dummy->obj, dummy->content);
+        efl_canvas_object_clip_set(dummy->content, pd->backclip);
+
+        dummy->content_num = -1;
+        dummy->content = NULL;
+        dummy->visible = EINA_FALSE;
+     }
 }
 
 EOLIAN static void

-- 


Reply via email to