diff options
author | Teng-Hui Zhu <ztenghui@google.com> | 2011-11-14 10:37:16 -0800 |
---|---|---|
committer | Teng-Hui Zhu <ztenghui@google.com> | 2011-11-23 10:47:51 -0800 |
commit | 7ae9f3ab5517a3d58cc1f462d4a920cbe42a4213 (patch) | |
tree | 3a197417cb973337343dca6270a5b424efc6cf6c /core | |
parent | 7257a32b9ac7cbbb47659ed7bea4ab47e74ac3ec (diff) | |
download | frameworks_base-7ae9f3ab5517a3d58cc1f462d4a920cbe42a4213.zip frameworks_base-7ae9f3ab5517a3d58cc1f462d4a920cbe42a4213.tar.gz frameworks_base-7ae9f3ab5517a3d58cc1f462d4a920cbe42a4213.tar.bz2 |
WebView animation support
Fix the jumping issue when double tapping
bug:4982054
Change-Id: Ifb67030a3132fe3820a1fcc8ffc97a1ab474c223
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/webkit/ZoomManager.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/java/android/webkit/ZoomManager.java b/core/java/android/webkit/ZoomManager.java index 84d00c9..c69f7f0 100644 --- a/core/java/android/webkit/ZoomManager.java +++ b/core/java/android/webkit/ZoomManager.java @@ -493,6 +493,9 @@ class ZoomManager { if (mHardwareAccelerated) { mWebView.updateScrollCoordinates(mWebView.getScrollX() - tx, mWebView.getScrollY() - ty); + // By adding webView matrix, we need to offset the canvas a bit + // to make the animation smooth. + canvas.translate(tx, ty); setZoomScale(zoomScale, false); if (mZoomScale == 0) { |