Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / plugins / gesture-events-scrolled.html
blob5c473959b2889328054b15a44bfa0e34888282bb
1 <html>
2 <head>
3 <style>
4 body {
5 height: 2000px;
7 #plugin {
8 position: absolute;
9 top: 500px;
10 width: 150px;
11 height: 150px;
13 </style>
14 </head>
16 <body>
17 <embed id="plugin" type="application/x-webkit-test-webplugin" primitive="triangle" background-color="green" primitive-color="blue"></embed>
18 <script>
20 if (!window.testRunner) {
21 document.write("This test does not work in manual mode.");
22 } else {
23 testRunner.dumpAsText();
24 internals.updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks();
26 // Scroll so the plugin is 100px down the page
27 window.scroll(0, 400);
29 // These events should not reach the plugin since it's futher down on the page.
30 eventSender.gestureShowPress(30, 30);
31 eventSender.gestureShowPress(30, 530);
33 // Send some gesture events to the plugin.
34 var positionX = 30;
35 var positionY = 110;
36 eventSender.gestureTap(positionX, positionY);
37 eventSender.gestureScrollBegin(positionX, positionY);
38 eventSender.gestureScrollUpdate(30, 0);
39 eventSender.gestureScrollUpdate(30, 0, true);
40 eventSender.gestureScrollEnd(0, 0);
43 </script>
44 </body>
45 </html>