Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(370)

Side by Side Diff: LayoutTests/compositing/iframes/repaint-after-losing-scrollbars.html

Issue 181653006: Remove testRunner.display() from most compositing/ tests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Revert change to plugin test Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../../resources/run-after-display.js"></script>
2 <!-- Tests that overflow controls are repainted after compositing is disabled. T here should be three green squares and no visible overflow controls --> 3 <!-- Tests that overflow controls are repainted after compositing is disabled. T here should be three green squares and no visible overflow controls -->
3 <style> 4 <style>
4 .composited { 5 .composited {
5 -webkit-transform:translateZ(0); 6 -webkit-transform:translateZ(0);
6 } 7 }
7 8
8 .container { 9 .container {
9 width: 100px; 10 width: 100px;
10 height:100px; 11 height:100px;
11 position:absolute; 12 position:absolute;
12 background-color: green; 13 background-color: green;
13 overflow:auto; 14 overflow:auto;
14 border: 0px; 15 border: 0px;
15 } 16 }
16 17
17 </style> 18 </style>
18 <body onload="test()"> 19 <body onload="test()">
19 <iframe id="vertical" class="composited container" src="resources/repaint-after- losing-scrollbars-iframe.html"></iframe> 20 <iframe id="vertical" class="composited container" src="resources/repaint-after- losing-scrollbars-iframe.html"></iframe>
20 <iframe id="horizontal" class="composited container" style="left: 150px" src="re sources/repaint-after-losing-scrollbars-iframe.html"></iframe> 21 <iframe id="horizontal" class="composited container" style="left: 150px" src="re sources/repaint-after-losing-scrollbars-iframe.html"></iframe>
21 <iframe id="both" class="composited container" style="left: 300px" src="resource s/repaint-after-losing-scrollbars-iframe.html"></iframe> 22 <iframe id="both" class="composited container" style="left: 300px" src="resource s/repaint-after-losing-scrollbars-iframe.html"></iframe>
22 </body> 23 </body>
23 <script> 24 <script>
24 function finishTest() { 25 function finishTest() {
25 document.getElementById("vertical").contentDocument.body.classList.remove("t all"); // topmost iframe loses a vertical scrollbar 26 document.getElementById("vertical").contentDocument.body.classList.remove("t all"); // topmost iframe loses a vertical scrollbar
26 document.getElementById("horizontal").contentDocument.body.classList.remove( "wide"); // middle iframe loses a horizontal scrollbar 27 document.getElementById("horizontal").contentDocument.body.classList.remove( "wide"); // middle iframe loses a horizontal scrollbar
27 document.getElementById("both").contentDocument.body.classList.remove("wide" ); // bottom iframe loses both 28 document.getElementById("both").contentDocument.body.classList.remove("wide" ); // bottom iframe loses both
28 document.getElementById("both").contentDocument.body.classList.remove("tall" ); // bottom iframe loses both 29 document.getElementById("both").contentDocument.body.classList.remove("tall" ); // bottom iframe loses both
30 if (window.testRunner)
31 testRunner.notifyDone();
29 } 32 }
30 33
31 function test() { 34 function test() {
32 document.getElementById("vertical").contentDocument.body.classList.add("tall "); // topmost iframe starts with a vertical scrollbar 35 document.getElementById("vertical").contentDocument.body.classList.add("tall "); // topmost iframe starts with a vertical scrollbar
33 document.getElementById("horizontal").contentDocument.body.classList.add("wi de"); // middle iframe starts with a horizontal scrollbar 36 document.getElementById("horizontal").contentDocument.body.classList.add("wi de"); // middle iframe starts with a horizontal scrollbar
34 document.getElementById("both").contentDocument.body.classList.add("wide"); // bottom iframe starts with both 37 document.getElementById("both").contentDocument.body.classList.add("wide"); // bottom iframe starts with both
35 document.getElementById("both").contentDocument.body.classList.add("tall"); // vertical and horizontal scrollbars 38 document.getElementById("both").contentDocument.body.classList.add("tall"); // vertical and horizontal scrollbars
36 if (window.testRunner) { 39 if (window.testRunner) {
37 testRunner.dumpAsTextWithPixelResults(); 40 testRunner.dumpAsTextWithPixelResults();
38 testRunner.display(); // Paint once with all overflow controls visible. 41 testRunner.waitUntilDone();
39 finishTest(); 42 }
40 } else 43 runAfterDisplay(finishTest);
41 window.setTimeout(finishTest, 5000);
42 } 44 }
43 </script> 45 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698