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

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

Issue 103823003: Implement touch-action pan-x/pan-y handling on the main thread (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@issue1
Patch Set: incorporated review comments Created 7 years 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 | « Source/core/page/EventHandler.cpp ('k') | Source/web/tests/data/touch-action-pan.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/tests/TouchActionTest.cpp
diff --git a/Source/web/tests/TouchActionTest.cpp b/Source/web/tests/TouchActionTest.cpp
old mode 100644
new mode 100755
index 56cffb3bb2dc64da76fb608d36b7f615190c3441..e2a0aa3f0c99dec462a3c3dbcada840edad3be13
--- a/Source/web/tests/TouchActionTest.cpp
+++ b/Source/web/tests/TouchActionTest.cpp
@@ -262,6 +262,12 @@ void TouchActionTest::runTestOnTree(WebCore::Node* root, WebView* webView, Touch
if (client.touchActionSetCount()) {
if (expectedAction == "none") {
EXPECT_EQ(WebTouchActionNone, client.lastTouchAction()) << failureContextPos;
+ } else if (expectedAction == "pan-x") {
+ EXPECT_EQ(WebTouchActionPanX, client.lastTouchAction()) << failureContextPos;
+ } else if (expectedAction == "pan-y") {
+ EXPECT_EQ(WebTouchActionPanY, client.lastTouchAction()) << failureContextPos;
+ } else if (expectedAction == "pan-x-y") {
+ EXPECT_EQ((WebTouchActionPanX | WebTouchActionPanY), client.lastTouchAction()) << failureContextPos;
} else {
FAIL() << "Unrecognized expected-action \"" << expectedAction.string().ascii().data()
<< "\" " << failureContextPos;
@@ -313,4 +319,9 @@ TEST_F(TouchActionTest, ShadowDOM)
runShadowDOMTest("touch-action-shadow-dom.html");
}
+TEST_F(TouchActionTest, Pan)
+{
+ runTouchActionTest("touch-action-pan.html");
+}
+
}
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/web/tests/data/touch-action-pan.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698