| OLD | NEW |
| 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 29 matching lines...) Expand all Loading... |
| 40 namespace blink { | 40 namespace blink { |
| 41 | 41 |
| 42 class Animation; | 42 class Animation; |
| 43 class Element; | 43 class Element; |
| 44 class FloatBox; | 44 class FloatBox; |
| 45 | 45 |
| 46 class CORE_EXPORT CompositorAnimations { | 46 class CORE_EXPORT CompositorAnimations { |
| 47 public: | 47 public: |
| 48 static CompositorAnimations* instance() { return instance(0); } | 48 static CompositorAnimations* instance() { return instance(0); } |
| 49 static void setInstanceForTesting(CompositorAnimations* newInstance) { insta
nce(newInstance); } | 49 static void setInstanceForTesting(CompositorAnimations* newInstance) { insta
nce(newInstance); } |
| 50 static bool isCompositableProperty(CSSPropertyID property) { return property
== CSSPropertyOpacity || property == CSSPropertyTransform || property == CSSPro
pertyWebkitFilter; } | 50 static bool isCompositableProperty(CSSPropertyID); |
| 51 static CSSPropertyID CompositableProperties[3]; | 51 static const CSSPropertyID compositableProperties[6]; |
| 52 | 52 |
| 53 virtual bool isCandidateForAnimationOnCompositor(const Timing&, const Elemen
t&, const Animation*, const EffectModel&, double animationPlaybackRate); | 53 virtual bool isCandidateForAnimationOnCompositor(const Timing&, const Elemen
t&, const Animation*, const EffectModel&, double animationPlaybackRate); |
| 54 virtual void cancelIncompatibleAnimationsOnCompositor(const Element&, const
Animation&, const EffectModel&); | 54 virtual void cancelIncompatibleAnimationsOnCompositor(const Element&, const
Animation&, const EffectModel&); |
| 55 virtual bool canStartAnimationOnCompositor(const Element&); | 55 virtual bool canStartAnimationOnCompositor(const Element&); |
| 56 // FIXME: This should return void. We should know ahead of time whether thes
e animations can be started. | 56 // FIXME: This should return void. We should know ahead of time whether thes
e animations can be started. |
| 57 virtual bool startAnimationOnCompositor(const Element&, int group, double st
artTime, double timeOffset, const Timing&, const Animation&, const EffectModel&,
Vector<int>& startedAnimationIds, double animationPlaybackRate); | 57 virtual bool startAnimationOnCompositor(const Element&, int group, double st
artTime, double timeOffset, const Timing&, const Animation&, const EffectModel&,
Vector<int>& startedAnimationIds, double animationPlaybackRate); |
| 58 virtual void cancelAnimationOnCompositor(const Element&, const Animation&, i
nt id); | 58 virtual void cancelAnimationOnCompositor(const Element&, const Animation&, i
nt id); |
| 59 virtual void pauseAnimationForTestingOnCompositor(const Element&, const Anim
ation&, int id, double pauseTime); | 59 virtual void pauseAnimationForTestingOnCompositor(const Element&, const Anim
ation&, int id, double pauseTime); |
| 60 | 60 |
| 61 virtual bool canAttachCompositedLayers(const Element&, const Animation&); | 61 virtual bool canAttachCompositedLayers(const Element&, const Animation&); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 72 if (newInstance) { | 72 if (newInstance) { |
| 73 instance = newInstance; | 73 instance = newInstance; |
| 74 } | 74 } |
| 75 return instance; | 75 return instance; |
| 76 } | 76 } |
| 77 }; | 77 }; |
| 78 | 78 |
| 79 } // namespace blink | 79 } // namespace blink |
| 80 | 80 |
| 81 #endif | 81 #endif |
| OLD | NEW |