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

Unified Diff: sky/engine/core/animation/SampledEffect.cpp

Issue 1229273004: Remove Animations and Transitions. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 5 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 | « sky/engine/core/animation/SampledEffect.h ('k') | sky/engine/core/animation/StringKeyframe.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/animation/SampledEffect.cpp
diff --git a/sky/engine/core/animation/SampledEffect.cpp b/sky/engine/core/animation/SampledEffect.cpp
deleted file mode 100644
index 6e7e5b25ba0a0055d1ad6751065008aea355d181..0000000000000000000000000000000000000000
--- a/sky/engine/core/animation/SampledEffect.cpp
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "sky/engine/core/animation/SampledEffect.h"
-
-#include "sky/engine/core/animation/StyleInterpolation.h"
-
-namespace blink {
-
-SampledEffect::SampledEffect(Animation* animation, PassOwnPtr<Vector<RefPtr<Interpolation> > > interpolations)
- : m_animation(animation)
-#if !ENABLE(OILPAN)
- , m_player(animation->player())
-#endif
- , m_interpolations(interpolations)
- , m_sequenceNumber(animation->player()->sequenceNumber())
- , m_priority(animation->priority())
-{
- ASSERT(m_interpolations && !m_interpolations->isEmpty());
-}
-
-bool SampledEffect::canChange() const
-{
-#if ENABLE(OILPAN)
- return m_animation;
-#else
- if (!m_animation)
- return false;
- // FIXME: This check won't be needed when Animation and AnimationPlayer are moved to Oilpan.
- return !m_player->canFree();
-#endif
-}
-
-void SampledEffect::clear()
-{
-#if !ENABLE(OILPAN)
- m_player = nullptr;
-#endif
- m_animation = nullptr;
- m_interpolations->clear();
-}
-
-void SampledEffect::removeReplacedInterpolationsIfNeeded(const BitArray<numCSSProperties>& replacedProperties)
-{
- if (canChange() && m_animation->isCurrent())
- return;
-
- size_t dest = 0;
- for (size_t i = 0; i < m_interpolations->size(); i++) {
- if (!replacedProperties.get(toStyleInterpolation(m_interpolations->at(i).get())->id()))
- m_interpolations->at(dest++) = m_interpolations->at(i);
- }
- m_interpolations->shrink(dest);
-}
-
-} // namespace blink
« no previous file with comments | « sky/engine/core/animation/SampledEffect.h ('k') | sky/engine/core/animation/StringKeyframe.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698