| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <style> | 4 <style> |
| 5 div.block { height: 400px; border: 1px solid black; margin:10px; } | 5 div.block { height: 400px; border: 1px solid black; margin:10px; } |
| 6 </style> | 6 </style> |
| 7 </head> | 7 </head> |
| 8 <body> | 8 <body> |
| 9 <div> | 9 <div> |
| 10 Following actions must not emit resize events: page load, dynamic conten
t generation and page scaling.<br/> | 10 Following actions must not emit resize events: page load, dynamic conten
t generation and page scaling.<br/> |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 window.internals.setPageScaleFactor(3, 0, 0); | 47 window.internals.setPageScaleFactor(3, 0, 0); |
| 48 setTimeout(changeFixedLayoutSize, 20); | 48 setTimeout(changeFixedLayoutSize, 20); |
| 49 } | 49 } |
| 50 function changeFixedLayoutSize() { | 50 function changeFixedLayoutSize() { |
| 51 if (window.testRunner) | 51 if (window.testRunner) |
| 52 testRunner.setFixedLayoutSize(1600, 1600); | 52 testRunner.setFixedLayoutSize(1600, 1600); |
| 53 setTimeout(finish, 20); | 53 setTimeout(finish, 20); |
| 54 } | 54 } |
| 55 function finish() { | 55 function finish() { |
| 56 // setFixedLayoutSize() must emit a resize event. | 56 // setFixedLayoutSize() must emit a resize event. |
| 57 shouldBe("resizeEventCount", "1"); | 57 // We call setFixedLayoutSize twice. Once before the load event, and
then a second time after load. |
| 58 shouldBe("resizeEventCount", "2"); |
| 58 if (window.testRunner) | 59 if (window.testRunner) |
| 59 testRunner.notifyDone(); | 60 testRunner.notifyDone(); |
| 60 } | 61 } |
| 61 window.onload = test; | 62 window.onload = test; |
| 62 </script> | 63 </script> |
| 63 </body> | 64 </body> |
| 64 </html> | 65 </html> |
| OLD | NEW |