| <!DOCTYPE html> |
| <html> |
| <script>jsTestIsAsync = true;</script> |
| <script src="../../resources/js-test-pre.js"></script> |
| <head> |
| <title>This tests that we don't leave bits behind, when the self-painting child layer get destroyed while the parent becomes overflow: hidden.</title> |
| <style> |
| #container { |
| position: relative; |
| overflow: visible; |
| height: 100px; |
| width: 100px; |
| } |
| |
| #content { |
| position: relative; |
| height: 200px; |
| width: 200px; |
| background: green; |
| } |
| </style> |
| </head> |
| <body> |
| <div id=container> |
| <div id=content></div> |
| </div> |
| <script> |
| setTimeout( |
| function() { |
| if (window.internals) |
| internals.startTrackingRepaints(); |
| document.getElementById("container").style.overflow = "hidden"; |
| document.getElementById("content").style.position = "static"; |
| document.body.offsetWidth; |
| |
| if (window.internals) { |
| shouldNotBe("window.internals.repaintRectsAsText().indexOf('200 200')", "-1"); |
| internals.stopTrackingRepaints(); |
| } |
| finishJSTest(); |
| }, 0); |
| </script> |
| </body> |
| <script src="../../resources/js-test-post.js"></script> |
| </html> |