Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(280)

Unified Diff: Source/WebKit/chromium/tests/WebFrameTest.cpp

Issue 19281007: Allow zoom-in to a target rect when tapping multiple targets. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/web/WebViewImpl.h » ('j') | Source/web/WebViewImpl.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebKit/chromium/tests/WebFrameTest.cpp
diff --git a/Source/WebKit/chromium/tests/WebFrameTest.cpp b/Source/WebKit/chromium/tests/WebFrameTest.cpp
index ac3158719c1ed8d1d615e058ac22feeb6a5ca04e..e845fc733b2caf72a63fbc74900f716596e580f4 100644
--- a/Source/WebKit/chromium/tests/WebFrameTest.cpp
+++ b/Source/WebKit/chromium/tests/WebFrameTest.cpp
@@ -1209,7 +1209,7 @@ TEST_F(WebFrameTest, DivAutoZoomParamsTest)
void simulateDoubleTap(WebViewImpl* webViewImpl, WebPoint& point, float& scale)
{
- webViewImpl->animateZoomAroundPoint(point, WebViewImpl::DoubleTap);
+ webViewImpl->animateZoomToRect(WebCore::IntRect(point.x, point.y, 0, 0), WebViewImpl::DoubleTap);
EXPECT_TRUE(webViewImpl->fakeDoubleTapAnimationPendingForTesting());
WebCore::IntSize scrollDelta = webViewImpl->fakeDoubleTapTargetPositionForTesting() - webViewImpl->mainFrameImpl()->frameView()->scrollPosition();
float scaleDelta = webViewImpl->fakeDoubleTapPageScaleFactorForTesting() / webViewImpl->pageScaleFactor();
@@ -1261,7 +1261,7 @@ TEST_F(WebFrameTest, DivAutoZoomMultipleDivsTest)
// If we didn't yet get an auto-zoom update and a second double-tap arrives, should go back to minimum scale.
webViewImpl->applyScrollAndScale(WebSize(), 1.1f);
- webViewImpl->animateZoomAroundPoint(topPoint, WebViewImpl::DoubleTap);
+ webViewImpl->animateZoomToRect(WebCore::IntRect(topPoint.x, topPoint.y, 0, 0), WebViewImpl::DoubleTap);
EXPECT_TRUE(webViewImpl->fakeDoubleTapAnimationPendingForTesting());
simulateDoubleTap(webViewImpl, bottomPoint, scale);
EXPECT_FLOAT_EQ(webViewImpl->minimumPageScaleFactor(), scale);
« no previous file with comments | « no previous file | Source/web/WebViewImpl.h » ('j') | Source/web/WebViewImpl.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698