5 <body onload=
"runTest();" style=
"width:2000px;height:2000px;margin:0px;padding:100px">
6 <button style=
"width:50px;height:50px;">B1
</button><button style=
"width:50px;height:50px;">B2
</button><button style=
"width:50px;height:50px;">B3
</button>
7 <div>This test is successful if elementFromPoint returns the correct element.
</div>
8 <div id=
"result"></div>
11 // Scroll before scaling so we scroll the layout viewport rather than the visual.
12 window
.scrollTo(100,100);
14 window
.internals
.setPageScaleFactor(2);
16 if (window
.testRunner
)
17 testRunner
.dumpAsText();
19 document
.getElementById("result").innerText
= document
.elementFromPoint(125, 25).innerText
;