| Index: third_party/WebKit/Source/core/animation/Animation.cpp
|
| diff --git a/third_party/WebKit/Source/core/animation/Animation.cpp b/third_party/WebKit/Source/core/animation/Animation.cpp
|
| index 62bb7c8f1af396eea05e5455e3b9f1c75de9b6d8..6fe5a0f1997df8e6a5b63fdd546263ac260e07dc 100644
|
| --- a/third_party/WebKit/Source/core/animation/Animation.cpp
|
| +++ b/third_party/WebKit/Source/core/animation/Animation.cpp
|
| @@ -97,6 +97,7 @@ Animation::Animation(ExecutionContext* executionContext, AnimationTimeline& time
|
| , m_compositorState(nullptr)
|
| , m_compositorPending(false)
|
| , m_compositorGroup(0)
|
| + , m_preFinalizerRegistered(false)
|
| , m_currentTimePending(false)
|
| , m_stateIsBeingUpdated(false)
|
| , m_effectSuppressed(false)
|
| @@ -903,6 +904,12 @@ void Animation::endUpdatingState()
|
| void Animation::createCompositorPlayer()
|
| {
|
| if (Platform::current()->isThreadedAnimationEnabled() && !m_compositorPlayer) {
|
| + // We only need to pre-finalize if we are running animations on the compositor.
|
| + if (!m_preFinalizerRegistered) {
|
| + ThreadState::current()->registerPreFinalizer(this);
|
| + m_preFinalizerRegistered = true;
|
| + }
|
| +
|
| ASSERT(Platform::current()->compositorSupport());
|
| m_compositorPlayer = CompositorAnimationPlayer::create();
|
| ASSERT(m_compositorPlayer);
|
|
|