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

Side by Side Diff: third_party/WebKit/Source/core/animation/ElementAnimations.h

Issue 1921503008: Blink CompositorWorker: Use CompositorElementId and CompositorIdToElementMap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@elementid
Patch Set: Vend ids via local blink nextCompositorElementId. Created 4 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
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 16 matching lines...) Expand all
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 ElementAnimations_h 31 #ifndef ElementAnimations_h
32 #define ElementAnimations_h 32 #define ElementAnimations_h
33 33
34 #include "core/animation/AnimationStack.h" 34 #include "core/animation/AnimationStack.h"
35 #include "core/animation/CustomCompositorAnimations.h" 35 #include "core/animation/CustomCompositorAnimations.h"
36 #include "core/animation/css/CSSAnimations.h" 36 #include "core/animation/css/CSSAnimations.h"
37 #include "platform/graphics/CompositorElementId.h"
37 #include "wtf/HashCountedSet.h" 38 #include "wtf/HashCountedSet.h"
38 #include "wtf/HashMap.h" 39 #include "wtf/HashMap.h"
39 #include "wtf/RefPtr.h" 40 #include "wtf/RefPtr.h"
40 #include "wtf/Vector.h" 41 #include "wtf/Vector.h"
41 42
42 namespace blink { 43 namespace blink {
43 44
44 class CSSAnimations; 45 class CSSAnimations;
45 46
46 using AnimationCountedSet = HeapHashCountedSet<WeakMember<Animation>>; 47 using AnimationCountedSet = HeapHashCountedSet<WeakMember<Animation>>;
(...skipping 25 matching lines...) Expand all
72 73
73 void restartAnimationOnCompositor(); 74 void restartAnimationOnCompositor();
74 75
75 void updateAnimationFlags(ComputedStyle&); 76 void updateAnimationFlags(ComputedStyle&);
76 void setAnimationStyleChange(bool animationStyleChange) { m_animationStyleCh ange = animationStyleChange; } 77 void setAnimationStyleChange(bool animationStyleChange) { m_animationStyleCh ange = animationStyleChange; }
77 78
78 const ComputedStyle* baseComputedStyle() const; 79 const ComputedStyle* baseComputedStyle() const;
79 void updateBaseComputedStyle(const ComputedStyle*); 80 void updateBaseComputedStyle(const ComputedStyle*);
80 void clearBaseComputedStyle(); 81 void clearBaseComputedStyle();
81 82
83 CompositorElementId compositorElementId() const { return m_compositorElement Id; }
84
82 DECLARE_TRACE(); 85 DECLARE_TRACE();
83 86
84 private: 87 private:
85 bool isAnimationStyleChange() const; 88 bool isAnimationStyleChange() const;
86 89
87 AnimationStack m_animationStack; 90 AnimationStack m_animationStack;
88 CustomCompositorAnimations m_customCompositorAnimations; 91 CustomCompositorAnimations m_customCompositorAnimations;
89 CSSAnimations m_cssAnimations; 92 CSSAnimations m_cssAnimations;
90 AnimationCountedSet m_animations; 93 AnimationCountedSet m_animations;
94 const CompositorElementId m_compositorElementId;
91 bool m_animationStyleChange; 95 bool m_animationStyleChange;
92 RefPtr<ComputedStyle> m_baseComputedStyle; 96 RefPtr<ComputedStyle> m_baseComputedStyle;
93 97
94 // CSSAnimations and DeferredLegacyStyleInterpolation checks if a style chan ge is due to animation. 98 // CSSAnimations and DeferredLegacyStyleInterpolation checks if a style chan ge is due to animation.
95 friend class CSSAnimations; 99 friend class CSSAnimations;
96 friend class DeferredLegacyStyleInterpolation; 100 friend class DeferredLegacyStyleInterpolation;
97 }; 101 };
98 102
99 } // namespace blink 103 } // namespace blink
100 104
101 #endif // ElementAnimations_h 105 #endif // ElementAnimations_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698