diff options
-rw-r--r-- | Source/WebCore/platform/graphics/android/ScrollableLayerAndroid.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/Source/WebCore/platform/graphics/android/ScrollableLayerAndroid.cpp b/Source/WebCore/platform/graphics/android/ScrollableLayerAndroid.cpp index ca8f03c..2bb8b5c 100644 --- a/Source/WebCore/platform/graphics/android/ScrollableLayerAndroid.cpp +++ b/Source/WebCore/platform/graphics/android/ScrollableLayerAndroid.cpp @@ -18,10 +18,7 @@ bool ScrollableLayerAndroid::scrollTo(int x, int y) if (newX == scrollBounds.fLeft && newY == scrollBounds.fTop) return false; - SkScalar diffX = newX - scrollBounds.fLeft; - SkScalar diffY = newY - scrollBounds.fTop; - const SkPoint& pos = getPosition(); - setPosition(pos.fX - diffX, pos.fY - diffY); + setPosition(m_scrollLimits.fLeft - newX, m_scrollLimits.fTop - newY); return true; } |