OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <link rel="stylesheet" href="resources/flexbox.css"> | 4 <link rel="stylesheet" href="resources/flexbox.css"> |
| 5 <script src="../../resources/run-after-display.js"></script> |
5 <style> | 6 <style> |
6 body { | 7 body { |
7 margin: 0; | 8 margin: 0; |
8 } | 9 } |
9 .flexbox { | 10 .flexbox { |
10 background: #333; | 11 background: #333; |
11 } | 12 } |
12 .flex-item { | 13 .flex-item { |
13 height: 50px; | 14 height: 50px; |
14 margin: 20px; | 15 margin: 20px; |
(...skipping 15 matching lines...) Expand all Loading... |
30 <script> | 31 <script> |
31 function resizeFlexItem() { | 32 function resizeFlexItem() { |
32 var div = document.getElementById("flex-item-1"); | 33 var div = document.getElementById("flex-item-1"); |
33 div.classList.add("width"); | 34 div.classList.add("width"); |
34 if (window.testRunner) | 35 if (window.testRunner) |
35 testRunner.notifyDone(); | 36 testRunner.notifyDone(); |
36 }; | 37 }; |
37 window.onload = function() { | 38 window.onload = function() { |
38 if (window.testRunner) { | 39 if (window.testRunner) { |
39 testRunner.waitUntilDone(); | 40 testRunner.waitUntilDone(); |
40 testRunner.display(); | |
41 } else { | 41 } else { |
42 document.body.appendChild(document.createTextNode( | 42 document.body.appendChild(document.createTextNode( |
43 "Tests to make sure that when changing the size of one flex item cha
nges the " | 43 "Tests to make sure that when changing the size of one flex item cha
nges the " |
44 + "location of another flex item, we properly repaint. The repaint r
ect should " | 44 + "location of another flex item, we properly repaint. The repaint r
ect should " |
45 + "include the three flex items.")); | 45 + "include the three flex items.")); |
46 } | 46 } |
47 setTimeout(resizeFlexItem, 0); | 47 runAfterDisplay(resizeFlexItem, 0); |
48 }; | 48 }; |
49 </script> | 49 </script> |
50 </body></html> | 50 </body></html> |
OLD | NEW |