4 transform: translateZ(
0);
14 background-color: green;
18 <div id='scroller' class='composited scroller' style='pointer-events: none;'
>
19 <div>It should be possible to scroll this div.
</div>
22 <script src='../../resources/js-test.js'
></script>
23 <script src='../../resources/run-after-layout-and-paint.js'
></script>
25 <script type='text/javascript'
>
27 description('Verifies that toggling pointer-events correctly updates scrolling ' +
28 'layers in compositor.');
31 internals
.settings
.setPreferCompositingToLCDTextEnabled(true);
33 function isUsingCompositedScrolling(layer
) {
34 if (layer
.bounds
[1] == 1000)
37 for (var i
= 0; i
< layer
.children
.length
; i
++) {
38 if (isUsingCompositedScrolling(layer
.children
[i
]))
46 documentLayerTree
= JSON
.parse(window
.internals
.layerTreeAsText(document
));
47 shouldBe('isUsingCompositedScrolling(documentLayerTree)', 'false');
49 // removing 'pointer-events: none' should cause composited scrolling
50 document
.getElementById('scroller').style
.pointerEvents
= '';
51 runAfterLayoutAndPaint(function() {
52 documentLayerTree
= JSON
.parse(window
.internals
.layerTreeAsText(document
));
53 shouldBe('isUsingCompositedScrolling(documentLayerTree)', 'true');