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

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

Issue 814083003: Update animation when changes in animation keyframes are detected. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add tests for changing timing function Created 5 years, 12 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
« no previous file with comments | « Source/core/animation/Animation.h ('k') | Source/core/animation/AnimationNode.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 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 double activeDurationInternal() const; 97 double activeDurationInternal() const;
98 double startTimeInternal() const { return m_startTime; } 98 double startTimeInternal() const { return m_startTime; }
99 double endTimeInternal() const { return startTimeInternal() + specifiedTimin g().startDelay + activeDurationInternal() + specifiedTiming().endDelay; } 99 double endTimeInternal() const { return startTimeInternal() + specifiedTimin g().startDelay + activeDurationInternal() + specifiedTiming().endDelay; }
100 100
101 const AnimationPlayer* player() const { return m_player; } 101 const AnimationPlayer* player() const { return m_player; }
102 AnimationPlayer* player() { return m_player; } 102 AnimationPlayer* player() { return m_player; }
103 const Timing& specifiedTiming() const { return m_timing; } 103 const Timing& specifiedTiming() const { return m_timing; }
104 PassRefPtrWillBeRawPtr<AnimationNodeTiming> timing(); 104 PassRefPtrWillBeRawPtr<AnimationNodeTiming> timing();
105 void updateSpecifiedTiming(const Timing&); 105 void updateSpecifiedTiming(const Timing&);
106 106
107 unsigned styleChangeCounter() const { return m_styleChangeCounter; }
108 void updateStyleChangeCounter(unsigned styleChangeCounter) { m_styleChangeCo unter = std::max(m_styleChangeCounter, styleChangeCounter); }
109
107 void computedTiming(ComputedTimingProperties&); 110 void computedTiming(ComputedTimingProperties&);
108 ComputedTimingProperties computedTiming(); 111 ComputedTimingProperties computedTiming();
109 112
110 void setName(const String& name) { m_name = name; } 113 void setName(const String& name) { m_name = name; }
111 const String& name() const { return m_name; } 114 const String& name() const { return m_name; }
112 115
113 virtual void trace(Visitor*); 116 virtual void trace(Visitor*);
114 117
115 protected: 118 protected:
116 explicit AnimationNode(const Timing&, PassOwnPtrWillBeRawPtr<EventDelegate> = nullptr); 119 explicit AnimationNode(const Timing&, PassOwnPtrWillBeRawPtr<EventDelegate> = nullptr);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 bool isInPlay; 160 bool isInPlay;
158 double localTime; 161 double localTime;
159 double timeToForwardsEffectChange; 162 double timeToForwardsEffectChange;
160 double timeToReverseEffectChange; 163 double timeToReverseEffectChange;
161 } m_calculated; 164 } m_calculated;
162 mutable bool m_needsUpdate; 165 mutable bool m_needsUpdate;
163 mutable double m_lastUpdateTime; 166 mutable double m_lastUpdateTime;
164 String m_name; 167 String m_name;
165 168
166 const CalculatedTiming& ensureCalculated() const; 169 const CalculatedTiming& ensureCalculated() const;
170
171 private:
172 unsigned m_styleChangeCounter;
dstockwell 2014/12/29 01:59:52 This seems specific to CSSAnimations, we should st
shend 2014/12/29 03:21:37 Done.
167 }; 173 };
168 174
169 } // namespace blink 175 } // namespace blink
170 176
171 #endif // AnimationNode_h 177 #endif // AnimationNode_h
OLDNEW
« no previous file with comments | « Source/core/animation/Animation.h ('k') | Source/core/animation/AnimationNode.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698