5 <script src="../../resources/run-after-display.js"></script>
8 -webkit-transform: translatez(0);
13 background-color: blue;
16 #compositedInsideFixed {
17 -webkit-transform: translatez(0);
20 background-color: red;
30 background-color: cyan;
51 if (window.testRunner) {
52 testRunner.dumpAsText();
53 testRunner.waitUntilDone();
57 internals.settings.setLayerSquashingEnabled(true);
61 if (!window.internals)
64 // Display the test results only after test is done so that it does not affect repaint rect results.
65 document.getElementById('testResults').style.display = "block";
67 document.getElementById('Case1').textContent = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_REPAINT_RECTS);
70 window.scrollTo(0, 80);
71 runAfterDisplay(function() {
72 document.getElementById('Case2').textContent = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_REPAINT_RECTS);
73 if (window.testRunner) {
74 testRunner.notifyDone();
81 <body onload="runTest()">
82 <div id="description">
83 <p>This scenario verifies that the cyan "container" element scrolls properly with squashing enabled.</p>
87 <div id="compositedInsideFixed"></div>
90 <div id="container"></div>
92 <div id="testResults">
93 CASE 1, original layer tree:
94 <pre id="Case1"></pre>
96 CASE 2, scrolling y to 80, the "container" element should remain positioned with respect to the scrolled document, the fixed-pos layer compensates for the new scroll position:
97 <pre id="Case2"></pre>