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

Unified Diff: Source/core/animation/ActiveAnimations.h

Issue 23874019: Web Animations CSS: Start running animations on the compositor (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase and rename hasActiveAnimationOnCompositor to hasActiveAnimationsOnCompositor Created 7 years, 1 month 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
Index: Source/core/animation/ActiveAnimations.h
diff --git a/Source/core/animation/ActiveAnimations.h b/Source/core/animation/ActiveAnimations.h
index 58d4287950208736e5283db10df02fb113d18fca..6cb23879a5a38f981f799e8a3be5fe1523040bc8 100644
--- a/Source/core/animation/ActiveAnimations.h
+++ b/Source/core/animation/ActiveAnimations.h
@@ -40,6 +40,14 @@
namespace WebCore {
+class RenderObject;
+class Element;
+
+// FIXME: Move these to CompositorAnimations
+bool shouldCompositeForActiveAnimations(const RenderObject&, bool renderViewInCompositingMode);
+bool hasActiveAnimations(const RenderObject&, CSSPropertyID);
+bool hasActiveAnimationsOnCompositor(const RenderObject&, CSSPropertyID);
+
class ActiveAnimations {
public:
// Animations that are currently active for this element, their effects will be applied
@@ -49,6 +57,7 @@ public:
// will also be part of the default stack, but the mapping betwen animation name and
// player is kept here.
CSSAnimations& cssAnimations() { return m_cssAnimations; }
+ const CSSAnimations& cssAnimations() const { return m_cssAnimations; }
typedef HashCountedSet<Player*> PlayerSet;
// Players which have animations targeting this element.
@@ -56,6 +65,11 @@ public:
PlayerSet& players() { return m_players; }
bool isEmpty() const { return m_defaultStack.isEmpty() && m_cssAnimations.isEmpty(); }
+
+ bool hasActiveAnimations(CSSPropertyID) const;
+ bool hasActiveAnimationsOnCompositor(CSSPropertyID) const;
+ void cancelAnimationOnCompositor();
+
private:
AnimationStack m_defaultStack;
CSSAnimations m_cssAnimations;
« no previous file with comments | « LayoutTests/animations/opacity-transform-animation-expected.html ('k') | Source/core/animation/ActiveAnimations.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698