2 <script src=
"../../../resources/js-test.js"></script>
4 <iframe style=
"position:absolute; top:100px; left:100px;" src=
"./resources/touch-inside-iframe2.html"></iframe>
5 <p id=
"description"></p>
6 <div id=
"console"></div>
7 <script type=
"text/javascript">
8 description('Test iframes receive touches correctly.');
12 function testComplete(event
)
14 touch
= event
.touches
[0];
15 shouldBe("touch.pageX", "50");
16 shouldBe("touch.pageY", "50");
17 isSuccessfullyParsed();
18 testRunner
.notifyDone();
22 if (window
.eventSender
) {
23 // Touch the center of the div in the iframe.
24 // 100px is offset to iframe in main frame,
25 // 2px for the iframe border, 50px to get to centre of the div.
26 eventSender
.addTouchPoint(152, 152);
27 eventSender
.touchStart();
29 debug('This test requires DRT.');
33 if (window
.testRunner
) {
34 testRunner
.waitUntilDone();