blob: 38597750b12a083b8c18c5067f212d856110581e [file] [log] [blame]
timothy_horton@apple.combd1cdca2015-04-03 06:37:15 +00001<head>
2<script>
3window.onload = function () {
4 if (!window.testRunner) {
5 document.write("Test cannot be run manually.");
6 return;
7 }
8
9 testRunner.waitUntilDone();
ddkilzer@apple.com683a5162015-06-21 16:44:41 +000010
11 // Prevent WebKit1 hangs by ensuring layout is up-to-date before resize.
12 setTimeout(function() { window.resizeTo(200, 200); }, 0);
timothy_horton@apple.comfb158742015-04-04 00:07:54 +000013}
timothy_horton@apple.combd1cdca2015-04-03 06:37:15 +000014
timothy_horton@apple.comfb158742015-04-04 00:07:54 +000015window.onresize = function () {
ddkilzer@apple.com683a5162015-06-21 16:44:41 +000016 if (!window.testRunner) {
17 return;
18 }
19
timothy_horton@apple.combd1cdca2015-04-03 06:37:15 +000020 internals.setUseFixedLayout(true);
21 internals.setFixedLayoutSize(400, 400);
22
timothy_horton@apple.comfb158742015-04-04 00:07:54 +000023 testRunner.notifyDone();
timothy_horton@apple.combd1cdca2015-04-03 06:37:15 +000024}
25</script>
26</head>
27<body style="margin: 0;">
28<div style="width: 100%; height: 100%; position: absolute; background-color: green;"></div>
29<div style="width: 50vw; height: 50vh; position: absolute; background-color: blue;"></div>
ddkilzer@apple.com683a5162015-06-21 16:44:41 +000030</body>