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

Side by Side Diff: tools/perf/page_sets/perf_week/css-animations-simultaneous-by-updating-class.html

Issue 402433004: Test adding perf week tests as smoothness benchmark (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: g cl issue Created 6 years, 4 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
(Empty)
1 <!doctype html>
2 <meta name="viewport" content="width=device-width, user-scalable=no">
3 <container id="container"></container>
4 <script>
5 window.measurementReady = true;
6 var N = 1000;
7 var duration = 1000;
8
9 for (var i = 0; i < N; i++) {
10 var target = document.createElement('target');
11 container.appendChild(target);
12 }
13
14 function startAllAnimations() {
15 for (var i = 0; i < container.childNodes.length; i++) {
16 container.childNodes[i].classList.toggle('anim');
17 }
18 }
19 startAllAnimations();
20 setInterval(startAllAnimations, duration);
21 </script>
22
23 <style>
24 target {
25 display: inline-block;
26 width: 9px; height: 9px;
27 background: orange;
28 -webkit-animation: anim1 1s;
29 }
30 target.anim {
31 -webkit-animation: anim2 1s;
32 }
33 @-webkit-keyframes anim1 {
34 0% { opacity: 0; }
35 100% { opacity: 1; }
36 }
37 @-webkit-keyframes anim2 {
38 0% { opacity: 0; }
39 100% { opacity: 1; }
40 }
41 body {
42 margin: 0;
43 overflow: hidden;
44 }
45 container {
46 display: flex;
47 flex-flow: row wrap;
48 width: 550px;
49 height: 800px;
50 background: magenta;
51 }
52 </style>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698