| OLD | NEW |
| 1 <!DOCTYPE HTML> | 1 <!DOCTYPE HTML> |
| 2 <script src="resources/composited-scroll.js"></script> | 2 <script src="resources/composited-scroll.js"></script> |
| 3 <style> | 3 <style> |
| 4 #scroller { | 4 #scroller { |
| 5 overflow: scroll; | 5 overflow: scroll; |
| 6 height: 300px; | 6 height: 300px; |
| 7 width: 300px; | 7 width: 300px; |
| 8 background-color: red; | 8 background-color: red; |
| 9 } | 9 } |
| 10 | 10 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 if (window.testRunner) { | 35 if (window.testRunner) { |
| 36 window.testRunner.dumpAsText(); | 36 window.testRunner.dumpAsText(); |
| 37 window.testRunner.waitUntilDone(); | 37 window.testRunner.waitUntilDone(); |
| 38 } | 38 } |
| 39 | 39 |
| 40 var result = ""; | 40 var result = ""; |
| 41 | 41 |
| 42 onload = function() { | 42 onload = function() { |
| 43 if (window.internals) { | 43 if (window.internals) { |
| 44 result += "No clip path descendant (should be using composited scrolling
): "; | 44 result += "No clip path descendant (should be using composited scrolling
): "; |
| 45 if (isUsingCompositedScrolling(JSON.parse(window.internals.layerTreeAsTe
xt(document, window.internals.OUTPUT_CHILDREN_AS_LAYER_LIST)))) | 45 if (isUsingCompositedScrolling(JSON.parse(window.internals.layerTreeAsTe
xt(document)))) |
| 46 result += "Pass.\n"; | 46 result += "Pass.\n"; |
| 47 else | 47 else |
| 48 result += "Fail.\n" | 48 result += "Fail.\n" |
| 49 } | 49 } |
| 50 document.getElementById("inner").style.webkitClipPath = "polygon(40px 550px,
432px 302px,409px 237px,46px 156px)"; | 50 document.getElementById("inner").style.webkitClipPath = "polygon(40px 550px,
432px 302px,409px 237px,46px 156px)"; |
| 51 requestAnimationFrame(function() { | 51 requestAnimationFrame(function() { |
| 52 if (window.internals) { | 52 if (window.internals) { |
| 53 result += "Has clip path descendant (should not be using composited
scrolling): "; | 53 result += "Has clip path descendant (should not be using composited
scrolling): "; |
| 54 if (!isUsingCompositedScrolling(JSON.parse(window.internals.layerTre
eAsText(document, window.internals.OUTPUT_CHILDREN_AS_LAYER_LIST)))) | 54 if (!isUsingCompositedScrolling(JSON.parse(window.internals.layerTre
eAsText(document)))) |
| 55 result += "Pass.\n"; | 55 result += "Pass.\n"; |
| 56 else | 56 else |
| 57 result += "Fail.\n" | 57 result += "Fail.\n" |
| 58 } | 58 } |
| 59 | 59 |
| 60 if (window.testRunner) { | 60 if (window.testRunner) { |
| 61 window.testRunner.setCustomTextOutput(result); | 61 window.testRunner.setCustomTextOutput(result); |
| 62 window.testRunner.notifyDone(); | 62 window.testRunner.notifyDone(); |
| 63 } | 63 } |
| 64 }); | 64 }); |
| 65 }; | 65 }; |
| 66 </script> | 66 </script> |
| OLD | NEW |