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

Side by Side Diff: LayoutTests/compositing/visibility/visibility-image-layers-dynamic.html

Issue 9120020: Revert 98735 - Source/WebCore: The HTML5 video element in Safari does not respect "visibility:hid... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/963/
Patch Set: Created 8 years, 11 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
OLDNEW
(Empty)
1 <!DOCTYPE html>
2
3 <html>
4 <head>
5 <style>
6 .set {
7 position: absolute;
8 top: 8px;
9 }
10 .box {
11 height: 100px;
12 width: 100px;
13 }
14
15 .hidden {
16 visibility: hidden;
17 }
18
19 .container {
20 margin: 10px;
21 padding: 20px;
22 }
23 .container.hidden {
24 outline: 4px solid red;
25 }
26
27 .visible {
28 visibility: visible;
29 }
30 .should-be-hidden {
31 background-color: red !important;
32 }
33 .should-be-visible {
34 background-color: green !important;
35 }
36 .composited {
37 -webkit-transform: translateZ(0);
38 }
39
40 .visible-indicator {
41 background-color: green;
42 }
43
44 .hidden-indicator {
45 background-color: red;
46 }
47 </style>
48 <script>
49 if (window.layoutTestController) {
50 layoutTestController.dumpAsText();
51 layoutTestController.waitUntilDone();
52 }
53
54 function doTest()
55 {
56 if (window.layoutTestController)
57 document.getElementById('layers1').innerText = layoutTestController.laye rTreeAsText();
58
59 window.setTimeout(function() {
60 var firstImage = document.querySelectorAll('img')[0];
61 firstImage.style.visibility = 'visible';
62
63 if (window.layoutTestController)
64 document.getElementById('layers2').innerText = layoutTestController.la yerTreeAsText();
65
66 window.setTimeout(function() {
67 var secondContainer = document.querySelectorAll('.container')[1];
68 secondContainer.style.visibility = 'visible';
69
70 if (window.layoutTestController) {
71 document.getElementById('layers3').innerText = layoutTestControlle r.layerTreeAsText();
72 layoutTestController.notifyDone();
73 }
74 }, 0);
75 }, 0);
76 }
77 window.addEventListener('load', doTest, false);
78 </script>
79 </head>
80 <body>
81 <!-- Tests dynamic changes of visibility, using directly composited images. -->
82 <div class="composited container"><img src="../resources/thiswayup.png" clas s="hidden composited box"></div>
83 <div class="composited hidden container"><img src="../resources/thiswayup.pn g" class="composited box"></div>
84 <div class="composited hidden container"><img src="../resources/thiswayup.pn g" class="visible composited box"></div>
85
86 <h2>Initial</h2>
87 <pre id="layers1"></pre>
88
89 <h2>After step 1</h2>
90 <pre id="layers2"></pre>
91
92 <h2>After step 2</h2>
93 <pre id="layers3"></pre>
94 </body>
95 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698