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

Side by Side Diff: Source/core/animation/AnimationStack.h

Issue 1113173003: Web Animations: Update naming to reflect spec changes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: No, really. Created 5 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/animation/AnimationPlayerTest.cpp ('k') | Source/core/animation/AnimationStack.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 15 matching lines...) Expand all
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #ifndef AnimationStack_h 31 #ifndef AnimationStack_h
32 #define AnimationStack_h 32 #define AnimationStack_h
33 33
34 #include "core/CoreExport.h" 34 #include "core/CoreExport.h"
35 #include "core/animation/Animation.h" 35 #include "core/animation/Animation.h"
36 #include "core/animation/AnimationEffect.h" 36 #include "core/animation/EffectModel.h"
37 #include "core/animation/AnimationPlayer.h" 37 #include "core/animation/KeyframeEffect.h"
38 #include "core/animation/PropertyHandle.h"
38 #include "core/animation/SampledEffect.h" 39 #include "core/animation/SampledEffect.h"
39 #include "platform/geometry/FloatBox.h" 40 #include "platform/geometry/FloatBox.h"
40 #include "wtf/HashSet.h" 41 #include "wtf/HashSet.h"
41 #include "wtf/Vector.h" 42 #include "wtf/Vector.h"
42 43
43 namespace blink { 44 namespace blink {
44 45
45 using ActiveInterpolationMap = WillBeHeapHashMap<PropertyHandle, RefPtrWillBeMem ber<Interpolation>>; 46 using ActiveInterpolationMap = WillBeHeapHashMap<PropertyHandle, RefPtrWillBeMem ber<Interpolation>>;
46 47
47 class InertAnimation; 48 class InertAnimation;
48 49
49 class CORE_EXPORT AnimationStack { 50 class CORE_EXPORT AnimationStack {
50 DISALLOW_ALLOCATION(); 51 DISALLOW_ALLOCATION();
51 WTF_MAKE_NONCOPYABLE(AnimationStack); 52 WTF_MAKE_NONCOPYABLE(AnimationStack);
52 public: 53 public:
53 AnimationStack(); 54 AnimationStack();
54 55
55 void add(PassOwnPtrWillBeRawPtr<SampledEffect> effect) { m_effects.append(ef fect); } 56 void add(PassOwnPtrWillBeRawPtr<SampledEffect> effect) { m_effects.append(ef fect); }
56 bool isEmpty() const { return m_effects.isEmpty(); } 57 bool isEmpty() const { return m_effects.isEmpty(); }
57 bool hasActiveAnimationsOnCompositor(CSSPropertyID) const; 58 bool hasActiveAnimationsOnCompositor(CSSPropertyID) const;
58 static ActiveInterpolationMap activeInterpolations(AnimationStack*, const Wi llBeHeapVector<RawPtrWillBeMember<InertAnimation>>* newAnimations, const WillBeH eapHashSet<RawPtrWillBeMember<const AnimationPlayer>>* suppressedAnimationPlayer s, Animation::Priority, double timelineCurrentTime); 59 static ActiveInterpolationMap activeInterpolations(AnimationStack*, const Wi llBeHeapVector<RawPtrWillBeMember<InertAnimation>>* newAnimations, const WillBeH eapHashSet<RawPtrWillBeMember<const Animation>>* suppressedAnimations, KeyframeE ffect::Priority, double timelineCurrentTime);
59 60
60 bool getAnimatedBoundingBox(FloatBox&, CSSPropertyID) const; 61 bool getAnimatedBoundingBox(FloatBox&, CSSPropertyID) const;
61 DECLARE_TRACE(); 62 DECLARE_TRACE();
62 63
63 private: 64 private:
64 void removeClearedEffects(); 65 void removeClearedEffects();
65 66
66 // Effects sorted by priority. Lower priority at the start of the list. 67 // Effects sorted by priority. Lower priority at the start of the list.
67 WillBeHeapVector<OwnPtrWillBeMember<SampledEffect>> m_effects; 68 WillBeHeapVector<OwnPtrWillBeMember<SampledEffect>> m_effects;
68 69
69 friend class AnimationAnimationStackTest; 70 friend class AnimationAnimationStackTest;
70 }; 71 };
71 72
72 } // namespace blink 73 } // namespace blink
73 74
74 #endif // AnimationStack_h 75 #endif // AnimationStack_h
OLDNEW
« no previous file with comments | « Source/core/animation/AnimationPlayerTest.cpp ('k') | Source/core/animation/AnimationStack.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698