OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 </head> | 4 </head> |
5 <body onload="runTest();" style="width:2000px;height:2000px;margin:0px;padding:1
00px"> | 5 <body onload="runTest();" style="width:2000px;height:2000px;margin:0px;padding:1
00px"> |
6 <button style="width:50px;height:50px;">B1</button><button style="width:50px;hei
ght:50px;">B2</button><button style="width:50px;height:50px;">B3</button> | 6 <button style="width:50px;height:50px;">B1</button><button style="width:50px;hei
ght:50px;">B2</button><button style="width:50px;height:50px;">B3</button> |
7 <div>This test is successful if elementFromPoint returns the correct element.</d
iv> | 7 <div>This test is successful if elementFromPoint returns the correct element.</d
iv> |
8 <div id="result"></div> | 8 <div id="result"></div> |
9 <script> | 9 <script> |
10 function runTest() { | 10 function runTest() { |
| 11 window.scrollTo(100,100); |
11 if (window.internals) | 12 if (window.internals) |
12 window.internals.setPageScaleFactor(2); | 13 window.internals.setPageScaleFactor(2); |
13 window.scrollTo(100,100); | |
14 | 14 |
15 if (window.testRunner) | 15 if (window.testRunner) |
16 testRunner.dumpAsText(); | 16 testRunner.dumpAsText(); |
17 | 17 |
18 document.getElementById("result").innerText = document.elementFromPoint(125,
25).innerText; | 18 document.getElementById("result").innerText = document.elementFromPoint(125,
25).innerText; |
19 } | 19 } |
20 </script> | 20 </script> |
21 </script> | 21 </script> |
22 </body> | 22 </body> |
23 </html> | 23 </html> |
OLD | NEW |