|
1 <?xml version="1.0"?> |
|
2 <?xml-stylesheet href="chrome://global/skin" type="text/css"?> |
|
3 <?xml-stylesheet href="/tests/SimpleTest/test.css" type="text/css"?> |
|
4 |
|
5 <window title="Bug 465448" |
|
6 onload="loaded()" |
|
7 xmlns:html="http://www.w3.org/1999/xhtml" |
|
8 xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> |
|
9 |
|
10 <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> |
|
11 <script type="application/javascript" src="/tests/SimpleTest/EventUtils.js"></script> |
|
12 |
|
13 <script><![CDATA[ |
|
14 SimpleTest.waitForExplicitFinish(); |
|
15 var loadedCalled = false; |
|
16 var win = window.open("data:text/html,<body onload='window.opener.loaded()'><div style='height:200px; width:100px;'>", "_blank", "width=600,height=600"); |
|
17 |
|
18 function loaded() { |
|
19 if (!loadedCalled) { |
|
20 loadedCalled = true; |
|
21 return; |
|
22 } |
|
23 win.sizeToContent(); |
|
24 win.sizeToContent(); |
|
25 win.sizeToContent(); |
|
26 win.sizeToContent(); |
|
27 win.sizeToContent(); |
|
28 win.sizeToContent(); |
|
29 ok(win.innerWidth >= 100, "innerWidth"); |
|
30 ok(win.innerHeight >= 200, "innerHeight"); |
|
31 win.close(); |
|
32 SimpleTest.finish(); |
|
33 } |
|
34 ]]></script> |
|
35 |
|
36 <body xmlns="http://www.w3.org/1999/xhtml"> |
|
37 <p id="display"> |
|
38 </p> |
|
39 <div id="content" style="display: none"> |
|
40 </div> |
|
41 <pre id="test"> |
|
42 </pre> |
|
43 </body> |
|
44 |
|
45 </window> |