OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <style> | 4 <style> |
5 div { | 5 div { |
6 position: absolute; | 6 position: absolute; |
7 z-index: 1; | 7 z-index: 1; |
8 width: 10px; | 8 width: 10px; |
9 height: 10px; | 9 height: 10px; |
10 } | 10 } |
(...skipping 28 matching lines...) Expand all Loading... |
39 .overlap4 { | 39 .overlap4 { |
40 top: 300px; | 40 top: 300px; |
41 left: 235px; | 41 left: 235px; |
42 background-color: yellow; | 42 background-color: yellow; |
43 } | 43 } |
44 </style> | 44 </style> |
45 <script> | 45 <script> |
46 if (window.testRunner) | 46 if (window.testRunner) |
47 testRunner.dumpAsText(); | 47 testRunner.dumpAsText(); |
48 | 48 |
49 if (window.internals) | |
50 internals.settings.setLayerSquashingEnabled(true); | |
51 | |
52 function dump() { | 49 function dump() { |
53 if (!window.internals) | 50 if (!window.internals) |
54 return; | 51 return; |
55 var layers = document.createElement('pre'); | 52 var layers = document.createElement('pre'); |
56 layers.innerHTML = window.internals.layerTreeAsText(document); | 53 layers.innerHTML = window.internals.layerTreeAsText(document); |
57 document.body.appendChild(layers); | 54 document.body.appendChild(layers); |
58 } | 55 } |
59 | 56 |
60 window.onload = dump; | 57 window.onload = dump; |
61 </script> | 58 </script> |
62 </head> | 59 </head> |
63 | 60 |
64 <body> | 61 <body> |
65 <!-- | 62 <!-- |
66 If this test is working correctly, then the first two layers should not | 63 If this test is working correctly, then the first two layers should not |
67 squash together (as they would create a layer that's too sparse), but the | 64 squash together (as they would create a layer that's too sparse), but the |
68 third and fourth layers should squash together. | 65 third and fourth layers should squash together. |
69 --> | 66 --> |
70 <div class="composited"></div> | 67 <div class="composited"></div> |
71 <div id="A" class="overlap1"></div> | 68 <div id="A" class="overlap1"></div> |
72 <div id="B" class="overlap2"></div> | 69 <div id="B" class="overlap2"></div> |
73 <div id="C" class="overlap3"></div> | 70 <div id="C" class="overlap3"></div> |
74 <div id="D" class="overlap4"></div> | 71 <div id="D" class="overlap4"></div> |
75 </body> | 72 </body> |
76 </html> | 73 </html> |
OLD | NEW |