mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 12:25:53 +00:00
Bug 695569 - Prevent runaway kinetic scrolling [r=Cwiiis]
The kinetic scroll behaviour keeps trying to scroll the page until the "momentum" from the kinetic scroll runs out. This happens even if the content has reached the edge and cannot scroll any further. This results in the scroll indicators remaining visible even though there is no scrolling apparent to the user. This patch stops this behaviour.
This commit is contained in:
parent
4732ea7421
commit
fd65cae6a8
@ -1202,6 +1202,11 @@ var BrowserEventHandler = {
|
||||
self.panAccumulatedDeltaY -= ady;
|
||||
}
|
||||
|
||||
if (!self._elementCanScroll(panElement, -dx, -dy)) {
|
||||
BrowserApp.hideScrollbars();
|
||||
return;
|
||||
}
|
||||
|
||||
self._scrollElementBy(panElement, -dx, -dy);
|
||||
|
||||
if (Math.abs(self.panX) >= kMinKineticSpeed ||
|
||||
|
Loading…
Reference in New Issue
Block a user