Skip to content

Commit c9a3908

Browse files
Victoria LeaseAndroid (Google) Code Review
authored andcommitted
Merge "finalise scrolling before checking scroll position"
2 parents 9776ed7 + 3beeb1c commit c9a3908

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/java/android/webkit/WebViewClassic.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3896,6 +3896,7 @@ private boolean pinScrollBy(int dx, int dy, boolean animate, int animationDurati
38963896
// helper to pin the scrollTo parameters (already in view coordinates)
38973897
// returns true if the scroll was changed
38983898
private boolean pinScrollTo(int x, int y, boolean animate, int animationDuration) {
3899+
abortAnimation();
38993900
x = pinLocX(x);
39003901
y = pinLocY(y);
39013902
int dx = x - getScrollX();
@@ -3904,7 +3905,6 @@ private boolean pinScrollTo(int x, int y, boolean animate, int animationDuration
39043905
if ((dx | dy) == 0) {
39053906
return false;
39063907
}
3907-
abortAnimation();
39083908
if (animate) {
39093909
// Log.d(LOGTAG, "startScroll: " + dx + " " + dy);
39103910
mScroller.startScroll(getScrollX(), getScrollY(), dx, dy,

0 commit comments

Comments
 (0)