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

Side by Side Diff: Source/core/animation/css/CSSAnimations.h

Issue 21012002: Web Animations: Trigger and update CSS Animations backed by the Web Animations model (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 4 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
OLDNEW
1
1 /* 2 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 3 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 4 *
4 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
6 * met: 7 * met:
7 * 8 *
8 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 11 * * Redistributions in binary form must reproduce the above
(...skipping 10 matching lines...) Expand all
21 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 * (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. 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 30 */
30 31
31 #ifndef ActiveAnimations_h 32 #ifndef CSSAnimations_h
32 #define ActiveAnimations_h 33 #define CSSAnimations_h
33 34
34 #include "core/animation/AnimationStack.h" 35 #include "core/animation/Animation.h"
36
37 #include "core/animation/Player.h"
38 #include "core/rendering/style/RenderStyleConstants.h"
35 #include "wtf/HashMap.h" 39 #include "wtf/HashMap.h"
36 #include "wtf/RefPtr.h"
37 #include "wtf/Vector.h" 40 #include "wtf/Vector.h"
41 #include "wtf/text/AtomicString.h"
38 42
39 namespace WebCore { 43 namespace WebCore {
40 44
41 class AnimationStack; 45 class CSSAnimationDataList;
46 class Element;
47 class RenderObject;
48 class StyleResolver;
42 49
43 class ActiveAnimations { 50 class CSSAnimations FINAL {
51
44 public: 52 public:
45 AnimationStack* defaultStack() { return &m_defaultStack; } 53 CSSAnimations() { }
46 bool isEmpty() const { return !m_defaultStack.hasActiveAnimations(); } 54 bool isEmpty() const { return m_animations.isEmpty(); }
55 void cancel();
56 void update(Element*, EDisplay, StyleResolver*, const CSSAnimationDataList*) ;
57
47 private: 58 private:
48 AnimationStack m_defaultStack; 59 typedef HashMap<StringImpl*, Player*> AnimationMap;
49 // FIXME: Add AnimationStack for CSS Transitions 60 AnimationMap m_animations;
50 // FIXME: Add tracking data for CSS Animations
51 }; 61 };
52 62
53 } // namespace WebCore 63 } // namespace WebCore
54 64
55 #endif 65 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698