Reduce the scroll boundary bounce
parent
0f53cbbd95
commit
0f3faec35d
|
@ -184,5 +184,5 @@ class PagerView(ScrollView):
|
||||||
_, yscale = self.convert_distance_to_scroll(0, pxs)
|
_, yscale = self.convert_distance_to_scroll(0, pxs)
|
||||||
new = self.scroll_y + (yscale * {'u': 1, 'd': -1}[direction])
|
new = self.scroll_y + (yscale * {'u': 1, 'd': -1}[direction])
|
||||||
# bound to near [0, 1] to avoid "over-scrolling"
|
# bound to near [0, 1] to avoid "over-scrolling"
|
||||||
limited = max(-0.03, min(new, 1.03))
|
limited = max(-0.01, min(new, 1.01))
|
||||||
self.scroll_y = limited
|
self.scroll_y = limited
|
||||||
|
|
Loading…
Reference in New Issue