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

Unified Diff: Source/core/animation/AnimationPlayer.cpp

Issue 649563003: Web Animations: Compositor timeOffset should be sensitive to playback rate (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 | « ManualTests/animation/compositor-reverse.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/animation/AnimationPlayer.cpp
diff --git a/Source/core/animation/AnimationPlayer.cpp b/Source/core/animation/AnimationPlayer.cpp
index 25e505ad635548f48369f9db34319474f24fd1d4..61807539607ad24917ff29146a367abac146c846 100644
--- a/Source/core/animation/AnimationPlayer.cpp
+++ b/Source/core/animation/AnimationPlayer.cpp
@@ -623,7 +623,7 @@ bool AnimationPlayer::maybeStartAnimationOnCompositor()
double startTime = timeline()->zeroTime() + startTimeInternal();
double timeOffset = 0;
if (std::isnan(startTime)) {
- timeOffset = currentTimeInternal();
+ timeOffset = m_playbackRate < 0 ? sourceEnd() - currentTimeInternal() : currentTimeInternal();
}
return toAnimation(m_content.get())->maybeStartAnimationOnCompositor(startTime, timeOffset, m_playbackRate);
}
« no previous file with comments | « ManualTests/animation/compositor-reverse.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698