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

Unified Diff: PerformanceTests/Animation/api-balls-keyframe-animations.html

Issue 433423003: Animations: Make perf tests for web animations animate properly. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | PerformanceTests/Animation/api-set-current-time-balls-keyframe-animations.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: PerformanceTests/Animation/api-balls-keyframe-animations.html
diff --git a/PerformanceTests/Animation/api-balls-keyframe-animations.html b/PerformanceTests/Animation/api-balls-keyframe-animations.html
index af6cc2dfda28b0fcb673938191eea117bb132e94..f346116b552b1a58377a5b9522c99678d599626f 100644
--- a/PerformanceTests/Animation/api-balls-keyframe-animations.html
+++ b/PerformanceTests/Animation/api-balls-keyframe-animations.html
@@ -77,10 +77,9 @@ window.onload = function () {
for (var i = 0; i < maxParticles; i++) {
generateParticleKeyframes(i);
var particle = new Particle(i);
+ particle.start();
particles.push(particle);
}
- for (var i = 0; i < maxParticles; i++)
- particles[i].start();
startTrackingFrameRate();
}
@@ -133,8 +132,6 @@ function generateParticleKeyframes(index) {
}
allParticleKeyframes[index].push(generateKeyframe(t, x, y));
}
-
- return keyframes;
}
function generateKeyframe(t, x, y) {
@@ -151,7 +148,7 @@ function Particle(index)
domNode.style.backgroundColor = colors[Math.floor(Math.random() * colors.length)];
function start() {
- var player = domNode.animate(allParticleKeyframes[index], {easing: "linear", iterations: Infinity, direction: "alternate", duration: animationDuration});
+ var player = domNode.animate(allParticleKeyframes[index], {easing: "linear", iterations: Infinity, direction: "alternate", duration: animationDuration * 1000});
}
function destroy()
« no previous file with comments | « no previous file | PerformanceTests/Animation/api-set-current-time-balls-keyframe-animations.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698