elementary/scroller - fix the scroller to locate the current page correctly in case...
authorChunEon Park <hermet@hermet.pe.kr>
Thu, 10 Oct 2013 10:58:01 +0000 (19:58 +0900)
committerChunEon Park <hermet@hermet.pe.kr>
Thu, 10 Oct 2013 10:58:42 +0000 (19:58 +0900)
legacy/elementary/ChangeLog
legacy/elementary/NEWS
legacy/elementary/src/lib/elm_interface_scrollable.c

index 7891a1b..3e9e5b3 100644 (file)
 2013-10-08  Daesung Kim (ad960009)
 
         * ctxpopup : fix elm_object_content_unset didn't unpack content from box
+
+2013-10-10  ChunEon Park (Hermet)
+
+        * scroller : fix the scroller to locate the current page correctly
+        in case that the scroller is suddenly resized and then the drag
+        couldn't capture the page location.
index bff325a..1992150 100644 (file)
@@ -297,6 +297,7 @@ Fixes:
    * elm_player breaks theme due to poor namespacing
    * elm_popup breaks theme due to poor namespacing
    * ctxpopup: fix elm_object_content_unset didn't unpack content from box
+   * scroller : fix the scroller to locate the current page correctly in case that the scroller is suddenly resized and then the drag couldn't capture the page location.
 
 Removals:
 
index aecb77f..981ff00 100644 (file)
@@ -948,6 +948,13 @@ _elm_scroll_scroll_bar_read_and_update(
    x = _round(vx * (double)mx + minx, 1);
    y = _round(vy * (double)my + miny, 1);
    eo_do(sid->pan_obj, elm_obj_pan_pos_get(&px, &py));
+
+   if (!sid->freeze && _paging_is_enabled(sid))
+     {
+        x = _elm_scroll_page_x_get(sid, x - px, EINA_FALSE);
+        y = _elm_scroll_page_y_get(sid, y - py, EINA_FALSE);
+     }
+
    eo_do(sid->pan_obj, elm_obj_pan_pos_set(x, y));
    if ((px != x) || (py != y))
      {