diff options
Diffstat (limited to 'Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp')
-rw-r--r-- | Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp b/Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp index f2e1950..75f4a10 100644 --- a/Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp +++ b/Source/WebCore/platform/graphics/ca/win/CACFLayerTreeHost.cpp @@ -307,13 +307,14 @@ void CACFLayerTreeHost::contextDidChange() void CACFLayerTreeHost::notifyAnimationsStarted() { + // Send currentTime to the pending animations. This function is called by CACF in a callback + // which occurs after the drawInContext calls. So currentTime is very close to the time + // the animations actually start double currentTime = WTF::currentTime(); - double time = currentTime + lastCommitTime() - CACurrentMediaTime(); - ASSERT(time <= currentTime); HashSet<RefPtr<PlatformCALayer> >::iterator end = m_pendingAnimatedLayers.end(); for (HashSet<RefPtr<PlatformCALayer> >::iterator it = m_pendingAnimatedLayers.begin(); it != end; ++it) - (*it)->animationStarted(time); + (*it)->animationStarted(currentTime); m_pendingAnimatedLayers.clear(); } |