OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <head> |
| 3 <script src="../../js/resources/js-test-pre.js"></script> |
| 4 <script> |
| 5 var count = 0; |
| 6 var iframeStrict; |
| 7 var iframeQuirks; |
| 8 function verifyTest() { |
| 9 // Need to wait on both inner frames to load. |
| 10 if (count++ < 1) |
| 11 return; |
| 12 |
| 13 description('Test for scrollTop/Left values of document.body and documen
t.documentElement in documents in quirks and strict modes'); |
| 14 |
| 15 iframeStrict = document.getElementById("strict"); |
| 16 iframeQuirks = document.getElementById("quirks"); |
| 17 |
| 18 shouldBe("iframeStrict.contentDocument.documentElement.scrollTop", "5000
"); |
| 19 shouldBe("iframeStrict.contentDocument.documentElement.scrollLeft", "400
0"); |
| 20 shouldBe("iframeStrict.contentDocument.body.scrollTop", "0"); |
| 21 shouldBe("iframeStrict.contentDocument.body.scrollLeft", "0"); |
| 22 |
| 23 shouldBe("iframeQuirks.contentDocument.documentElement.scrollTop", "0"); |
| 24 shouldBe("iframeQuirks.contentDocument.documentElement.scrollLeft", "0")
; |
| 25 shouldBe("iframeQuirks.contentDocument.body.scrollTop", "5000"); |
| 26 shouldBe("iframeQuirks.contentDocument.body.scrollLeft", "4000"); |
| 27 finishJSTest(); |
| 28 } |
| 29 var jsTestIsAsync = true; |
| 30 </script> |
| 31 </head> |
| 32 <body> |
| 33 <iframe id="strict" src="resources/scrollable-iframe-strict.html"></iframe><
br> |
| 34 <iframe id="quirks" src="resources/scrollable-iframe-quirks.html"></iframe><
br> |
| 35 <script src="../../js/resources/js-test-post.js"></script> |
| 36 </body> |
| 37 </html> |
| 38 |
OLD | NEW |