diff options
author | Grace Kloba <klobag@google.com> | 2010-01-15 17:11:27 -0800 |
---|---|---|
committer | Grace Kloba <klobag@google.com> | 2010-01-18 15:30:59 -0800 |
commit | f167c4bfca57b5467f40f6cf25e10fb12183a9f3 (patch) | |
tree | 9ffe033971027b6ddd7d81b58a074e433cd4c302 | |
parent | 17b14bd36aba265ac6bffc2626d8db29713d7c45 (diff) | |
download | frameworks_base-f167c4bfca57b5467f40f6cf25e10fb12183a9f3.zip frameworks_base-f167c4bfca57b5467f40f6cf25e10fb12183a9f3.tar.gz frameworks_base-f167c4bfca57b5467f40f6cf25e10fb12183a9f3.tar.bz2 |
DO NOT MERGE
If pinched to overview mode, double tap should bring
it back to default instead of just setting the current
mode as overview mode.
-rw-r--r-- | core/java/android/webkit/WebView.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java index 023f61f..5b4ec60 100644 --- a/core/java/android/webkit/WebView.java +++ b/core/java/android/webkit/WebView.java @@ -4792,6 +4792,7 @@ public class WebView extends AbsoluteLayout } } settings.setDoubleTapToastCount(0); + boolean zoomToDefault = false; if ((settings.getLayoutAlgorithm() == WebSettings.LayoutAlgorithm.NARROW_COLUMNS) && (Math.abs(mActualScale - mTextWrapScale) >= 0.01f)) { setNewZoomScale(mActualScale, true, true); @@ -4807,9 +4808,12 @@ public class WebView extends AbsoluteLayout if (mScrollY < getTitleHeight()) mScrollY = 0; zoomWithPreview(newScale); } else if (Math.abs(mActualScale - mDefaultScale) >= 0.01f) { - mInZoomOverview = true; + zoomToDefault = true; } } else { + zoomToDefault = true; + } + if (zoomToDefault) { mInZoomOverview = false; int left = nativeGetBlockLeftEdge(mAnchorX, mAnchorY, mActualScale); if (left != NO_LEFTEDGE) { |