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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector-protocol/input/emulateTouchFromMouseEvent.html

Issue 2127163002: Limit PassiveDocumentEventListeners to touch and make it experimental (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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 unified diff | Download patch
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto r-protocol-test.js"></script> 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto r-protocol-test.js"></script>
4 <script> 4 <script>
5 5
6 window.addEventListener("touchstart", logEvent); 6 window.addEventListener("touchstart", logEvent, {passive: false});
7 window.addEventListener("touchmove", logEvent, {passive: false});
7 window.addEventListener("touchend", logEvent); 8 window.addEventListener("touchend", logEvent);
8 window.addEventListener("touchmove", logEvent);
9 window.addEventListener("touchcancel", logEvent); 9 window.addEventListener("touchcancel", logEvent);
10 10
11 function logEvent(event) 11 function logEvent(event)
12 { 12 {
13 event.preventDefault(); 13 event.preventDefault();
14 log("-----Event-----"); 14 log("-----Event-----");
15 log("type: " + event.type); 15 log("type: " + event.type);
16 if (event.shiftKey) 16 if (event.shiftKey)
17 log("shiftKey"); 17 log("shiftKey");
18 log("----Touches----"); 18 log("----Touches----");
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 InspectorTest.sendCommand("Page.enable", {}, function() { 121 InspectorTest.sendCommand("Page.enable", {}, function() {
122 InspectorTest.sendCommand("Page.setTouchEmulationEnabled", { enabled: tr ue }, sendNextEvent); 122 InspectorTest.sendCommand("Page.setTouchEmulationEnabled", { enabled: tr ue }, sendNextEvent);
123 }); 123 });
124 } 124 }
125 125
126 </script> 126 </script>
127 </head> 127 </head>
128 <body onload="runTest()"> 128 <body onload="runTest()">
129 </body> 129 </body>
130 </html> 130 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698