Video is not started even if play button has been pressed.
[framework/web/webkit-efl.git] / LayoutTests / fast / events / platform-wheelevent-paging-y-in-scrolling-page.html
1 <html>
2     <head>
3         <link rel="stylesheet" href="../js/resources/js-test-style.css">
4         <script src="../js/resources/js-test-pre.js"></script>
5         <script>
6             var givenScrollTop = 2; // Only page is scrolled per event, regardless of this number.
7             var givenScrollLeft = 0;
8             var expectedScrollTop = 525; // Window is 800x600. Scroll 87.5% of visible.
9             var expectedScrollLeft = 0;
10             var event;
11             var div;
12
13             if (window.testRunner)
14                 testRunner.waitUntilDone();
15
16             function dispatchWheelEvent()
17             {
18                 document.body.addEventListener("mousewheel", mousewheelHandler, false);
19
20                 if (window.eventSender) {
21                     eventSender.mouseMoveTo(100, 110);
22                     eventSender.continuousMouseScrollBy(-window.givenScrollLeft, -window.givenScrollTop, true);
23                 }
24
25                 setTimeout('checkOffsets();', 100);
26             }
27
28             function checkOffsets()
29             {
30                 shouldBe("document.body.scrollTop", "window.expectedScrollTop");
31                 shouldBe("document.body.scrollLeft", "window.expectedScrollLeft");
32
33                 if (window.testRunner)
34                     window.testRunner.notifyDone();
35             }
36
37             function mousewheelHandler(e)
38             {
39                 event = e;
40                 shouldBe("event.wheelDeltaY", "window.givenScrollTop * -3");
41                 shouldBe("event.wheelDeltaX", "0");
42
43                 if (e.wheelDeltaY)
44                     shouldBe("event.wheelDelta", "window.givenScrollTop * -3");
45                 else
46                     shouldBe("event.wheelDelta", "0");
47             }
48         </script>
49     </head>
50
51     <body style="margin:0" onload="setTimeout('dispatchWheelEvent();', 100)">
52         <div style="height:900px;width:400px">
53           <div style="background-color:red;height:900px;width:200px;position:relative;left:0px;top:0px"></div>
54           <div style="background-color:green;height:900px;width:200px;position:relative;left:200px;top:-900px"></div>
55         </div>
56         <div style="height:900px;width:400px">
57           <div style="background-color:blue;height:900px;width:200px;position:relative;left:0px;top:0px"></div>
58           <div style="background-color:yellow;height:900px;width:200px;position:relative;left:200px;top:-900px"></div>
59         </div>
60         <div id="console"></div>
61     </body>
62 </html>