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

Side by Side Diff: third_party/WebKit/LayoutTests/transitions/remove-accelerated-transition.html

Issue 2521493002: CSS Transitions: Reduce usage of -webkit prefix in layout tests (Closed)
Patch Set: Created 4 years 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
1 <html> 1 <html>
2 <head> 2 <head>
3 <style> 3 <style>
4 #a { 4 #a {
5 background-color: red; 5 background-color: red;
6 height: 100px; 6 height: 100px;
7 width: 100px; 7 width: 100px;
8 -webkit-transition: height 0.5s linear; 8 transition: height 0.5s linear;
9 overflow: hidden; 9 overflow: hidden;
10 } 10 }
11 11
12 #b { 12 #b {
13 background-color: blue; 13 background-color: blue;
14 height: 100px; 14 height: 100px;
15 width: 100px; 15 width: 100px;
16 -webkit-transition: -webkit-transform 0.5s linear; 16 transition: transform 0.5s linear;
17 } 17 }
18 </style> 18 </style>
19 <script> 19 <script>
20 if (window.testRunner) { 20 if (window.testRunner) {
21 testRunner.dumpAsText(); 21 testRunner.dumpAsText();
22 testRunner.waitUntilDone(); 22 testRunner.waitUntilDone();
23 } 23 }
24 24
25 function endTest() { 25 function endTest() {
26 if (window.testRunner) { 26 if (window.testRunner) {
27 testRunner.notifyDone(); 27 testRunner.notifyDone();
28 } 28 }
29 } 29 }
30 30
31 function startTest() { 31 function startTest() {
32 var a = document.getElementById("a"); 32 var a = document.getElementById("a");
33 var b = document.getElementById("b"); 33 var b = document.getElementById("b");
34 a.addEventListener("webkitTransitionEnd", endTest, false); 34 a.addEventListener("transitionend", endTest, false);
35 35
36 // Trigger transitions. 36 // Trigger transitions.
37 a.style.height = "0px"; 37 a.style.height = "0px";
38 b.style.webkitTransform = "translateX(10px)"; 38 b.style.transform = "translateX(10px)";
39 39
40 // Force layout. 40 // Force layout.
41 document.body.offsetHeight; 41 document.body.offsetHeight;
42 42
43 // Remove the transform transition by hiding its div. 43 // Remove the transform transition by hiding its div.
44 b.style.display = "none"; 44 b.style.display = "none";
45 } 45 }
46 </script> 46 </script>
47 </head> 47 </head>
48 <body onload="startTest()"> 48 <body onload="startTest()">
49 <div id="a">FAIL</div> 49 <div id="a">FAIL</div>
50 <div id="b"></div> 50 <div id="b"></div>
51 PASS 51 PASS
52 </body> 52 </body>
53 53
54 </html> 54 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698