Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / compositing / layer-creation / should-invoke-deferred-compositing.html
blob085a7c264ffae7c352c3c244366004b33a5ff3ff
1 <!DOCTYPE html>
3 <!-- crbug.com/336676 - layer creation should not accidentally skip requesting
4 the compositor for a frame to be produced. When there were no other
5 repaints or layout/style changes, the simple act of adding a layer was not
6 triggering compositing updates by itself. To recreate this scenario, an
7 out-of-flow canvas element is added to an empty composited layer. The
8 actual container layer does not get added to the tree until it realizes
9 that it receives the canvas content. -->
12 <html>
13 <head>
14 <script src="../../fast/repaint/resources/text-based-repaint.js"></script>
15 <style>
17 .composited {
18 transform: translatez(0);
21 .box {
22 position: absolute;
23 z-index: 1;
24 width: 300px;
25 height: 300px;
26 top: 0px;
27 left: 0px;
30 canvas {
31 position: absolute;
32 z-index: 1;
33 top: 0px;
34 left: 0px;
37 </style>
39 <script>
40 function repaintTest() {
41 var canvasElement = document.createElement("canvas");
42 canvasElement.width = 200;
43 canvasElement.height = 200;
44 var context = canvasElement.getContext("2d");
45 context.fillStyle = "green";
46 context.fillRect(80, 80, 50, 50);
47 document.getElementById("container").appendChild(canvasElement);
49 </script>
50 </head>
52 <body onload="runRepaintAndPixelTest()">
53 <div id="container" class="composited box"></div>
54 </body>
56 </html>