10 window
.enablePixelTesting
= true;
13 // The page scale, as set by window.internals.setPageScaleFactor should not be apparent
14 // to javascript. So, we expect scrolling to (100,100) to be page coordinates, rather
15 // than device pixels.
16 window
.scrollTo(100,100);
18 shouldBe("window.document.scrollingElement.scrollTop", "100");
19 shouldBe("window.document.scrollingElement.scrollLeft", "100");
20 shouldBe("window.scrollX", "100");
21 shouldBe("window.scrollY", "100");
24 function scaleWithEventSender() {
25 var scaleFactor
= 2.0;
27 internals
.setPageScaleFactor(scaleFactor
);
31 scaleWithEventSender();
35 <script src=
"../../resources/js-test.js"></script>
37 <body style=
"width:2000px; height:2000px; margin:0px;" onload=
"test();">
38 <div style=
"left:0; top:0; width:100px; height:100px; position:absolute; background:yellow;"></div>
39 <div style=
"left:100px; top:0; width:100px; height:100px; position:absolute; background:green;"></div>
40 <div style=
"left:200px; top:0; width:100px; height:100px; position:absolute; background:blue;"></div>
42 <div style=
"left:0; top:100px; width:100px; height:100px; position:absolute; background: green;"></div>
43 <div style=
"left:100px; top:100px; width:100px; height:100px; position:absolute; background:blue;"></div>
44 <div style=
"left:200px; top:100px; width:100px; height:100px; position:absolute; background:yellow;"></div>
46 <div id=
"console"></div>