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

Unified Diff: Source/web/tests/TouchActionTest.cpp

Issue 190723007: Fix tests to be compatible with Android scale initialization. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Reupload Created 6 years, 9 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
Index: Source/web/tests/TouchActionTest.cpp
diff --git a/Source/web/tests/TouchActionTest.cpp b/Source/web/tests/TouchActionTest.cpp
index 9e0e093e90645016194d7adbc05cac3d0d3d1c4f..ab72b0f16433e38dc6e0f8e4eed54c4d7551f4c7 100644
--- a/Source/web/tests/TouchActionTest.cpp
+++ b/Source/web/tests/TouchActionTest.cpp
@@ -168,6 +168,9 @@ WebView* TouchActionTest::setupTest(std::string file, TouchActionTrackingWebView
// Note that JavaScript must be enabled for shadow DOM tests.
WebView* webView = m_webViewHelper.initializeAndLoad(m_baseURL + file, true, 0, &client);
+ // Lock page scale factor to avoid zooming out to contents size.
+ m_webViewHelper.webView()->setPageScaleFactorLimits(1, 1);
+
// Set size to enable hit testing, and avoid line wrapping for consistency with browser.
webView->resize(WebSize(800, 1200));

Powered by Google App Engine
This is Rietveld 408576698