diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.com> | 2014-07-28 08:38:53 +0200 |
---|---|---|
committer | Tomaž Vajngerl <tomaz.vajngerl@collabora.com> | 2014-08-03 22:42:19 +0200 |
commit | 4d197ba48338c27265b7d23b7f73b4f8d6e6e6c3 (patch) | |
tree | e81c55fd8f6bb4aee9318cff9ed0e399f987927b | |
parent | LOAndroid3: log and handle error after document load (diff) | |
download | core-4d197ba48338c27265b7d23b7f73b4f8d6e6e6c3.tar.gz core-4d197ba48338c27265b7d23b7f73b4f8d6e6e6c3.zip |
LOAndroid3: don't update viewport if scrolled by (0,0)
Change-Id: I299ebf08d77c7f2a35ed551dfcdf17fa8d0a8d79
-rw-r--r-- | android/experimental/LOAndroid3/src/java/org/mozilla/gecko/gfx/LayerController.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/android/experimental/LOAndroid3/src/java/org/mozilla/gecko/gfx/LayerController.java b/android/experimental/LOAndroid3/src/java/org/mozilla/gecko/gfx/LayerController.java index 38de9c45a4a5..54def4a99f32 100644 --- a/android/experimental/LOAndroid3/src/java/org/mozilla/gecko/gfx/LayerController.java +++ b/android/experimental/LOAndroid3/src/java/org/mozilla/gecko/gfx/LayerController.java @@ -275,6 +275,10 @@ public class LayerController { * Scrolls the viewport by the given offset. You must hold the monitor while calling this. */ public void scrollBy(PointF point) { + if (point.equals(0,0)) { + return; + } + PointF origin = mViewportMetrics.getOrigin(); origin.offset(point.x, point.y); mViewportMetrics.setOrigin(origin); |