Chromium Code Reviews| Index: LayoutTests/compositing/change-from-paints-into-ancestor-to-paints-into-own-backing-for-intrinsic-reason.html |
| diff --git a/LayoutTests/compositing/change-from-paints-into-ancestor-to-paints-into-own-backing-for-intrinsic-reason.html b/LayoutTests/compositing/change-from-paints-into-ancestor-to-paints-into-own-backing-for-intrinsic-reason.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..2e58c939572fe53afd2b1a122000b9f5bf8672d3 |
| --- /dev/null |
| +++ b/LayoutTests/compositing/change-from-paints-into-ancestor-to-paints-into-own-backing-for-intrinsic-reason.html |
| @@ -0,0 +1,34 @@ |
| +<style> |
|
pdr.
2014/08/28 20:21:13
Nits: Add <!DOCTYPE html>, remove extra space betw
chrishtr
2014/08/28 20:27:56
Done.
|
| +.spinner { |
| + backface-visibility: hidden; |
| + background-color: blue; |
| + height: 100px; |
| + width: 100px; |
| +} |
| + |
| +.transparent { |
| + opacity: 0; |
| +} |
| + |
| +#container { |
| + -webkit-perspective: 1px; |
| + background-color: red; |
| + overflow: hidden; |
| +} |
| +</style> |
| +<script src="../fast/repaint/resources/text-based-repaint.js"></script> |
| +<div id="container"> |
| + <div class="spinner"></div> |
| + <br> |
| + <button onclick="repaintTest()">Close</button> |
| +</div> |
| +<script> |
| +// Tests that transitioning the container div from "composited but paints into ancestor" into "composited into own backing" |
| +// for intrinsic reasons (in this case due to opacity change) correctly invalidates the old paint invalidation backing (document) |
| +// before the change. |
| +function repaintTest() { |
| + document.getElementById('container').classList.add('transparent'); |
| +} |
| +if (window.testRunner) |
| + runRepaintTest(); |
| +</script> |