Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!DOCTYPE html> | |
| 2 <html> | |
| 3 <head> | |
|
Rick Byers
2015/01/07 21:58:12
Nit: html, head and body tags are normally omitted
skobes
2015/01/07 22:05:11
Done.
| |
| 4 <style> | |
| 5 | |
| 6 #container { | |
| 7 width: 200px; | |
| 8 height: 200px; | |
| 9 overflow: scroll; | |
| 10 } | |
| 11 | |
| 12 #content { | |
| 13 width: 7500px; | |
| 14 height: 7500px; | |
| 15 background-color: blue; | |
| 16 } | |
| 17 | |
| 18 </style> | |
| 19 <script src="../../resources/js-test.js"></script> | |
| 20 </head> | |
| 21 <body> | |
| 22 <div id="container"> | |
| 23 <div id="content"></div> | |
| 24 </div> | |
| 25 <div id="console"></div> | |
| 26 <script> | |
| 27 | |
| 28 var element = document.getElementById("container"); | |
| 29 | |
| 30 function runTest() { | |
| 31 testRunner.dumpAsText(); | |
| 32 testRunner.waitUntilDone(); | |
|
Rick Byers
2015/01/07 21:58:12
nit: you can simplify these two lines by just sett
skobes
2015/01/07 22:05:11
Done.
| |
| 33 | |
| 34 element.addEventListener("scroll", function() { | |
| 35 shouldBe("element.scrollTop", "80"); | |
| 36 testRunner.notifyDone(); | |
| 37 }); | |
| 38 | |
| 39 eventSender.mouseMoveTo(100, 100); | |
| 40 eventSender.mouseScrollBy(0, -2, /* paged */ false, | |
| 41 /* has_precise_scrolling_deltas */ true); | |
| 42 } | |
| 43 | |
| 44 description("Tests that a WebMouseWheelEvent with hasPreciseScrollingDeltas " + | |
| 45 "does not produce an animated scroll"); | |
| 46 | |
| 47 if (window.eventSender) | |
| 48 runTest(); | |
| 49 else | |
| 50 debug("FAIL: This test requires window.eventSender."); | |
| 51 | |
| 52 </script> | |
| 53 </body> | |
| 54 </html> | |
| OLD | NEW |