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

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

Issue 651103002: Web Animations: Compositor start notification should only apply to animations in a matching group (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase. Created 6 years 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 * 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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 class FloatBox; 42 class FloatBox;
43 43
44 class CompositorAnimations { 44 class CompositorAnimations {
45 public: 45 public:
46 static CompositorAnimations* instance() { return instance(0); } 46 static CompositorAnimations* instance() { return instance(0); }
47 static void setInstanceForTesting(CompositorAnimations* newInstance) { insta nce(newInstance); } 47 static void setInstanceForTesting(CompositorAnimations* newInstance) { insta nce(newInstance); }
48 48
49 virtual bool isCandidateForAnimationOnCompositor(const Timing&, const Animat ionEffect&, double playerPlaybackRate); 49 virtual bool isCandidateForAnimationOnCompositor(const Timing&, const Animat ionEffect&, double playerPlaybackRate);
50 virtual bool canStartAnimationOnCompositor(const Element&); 50 virtual bool canStartAnimationOnCompositor(const Element&);
51 // FIXME: This should return void. We should know ahead of time whether thes e animations can be started. 51 // FIXME: This should return void. We should know ahead of time whether thes e animations can be started.
52 virtual bool startAnimationOnCompositor(const Element&, double startTime, do uble timeOffset, const Timing&, const AnimationEffect&, Vector<int>& startedAnim ationIds, double playerPlaybackRate); 52 virtual bool startAnimationOnCompositor(const Element&, int group, double st artTime, double timeOffset, const Timing&, const AnimationEffect&, Vector<int>& startedAnimationIds, double playerPlaybackRate);
53 virtual void cancelAnimationOnCompositor(const Element&, int id); 53 virtual void cancelAnimationOnCompositor(const Element&, int id);
54 virtual void pauseAnimationForTestingOnCompositor(const Element&, int id, do uble pauseTime); 54 virtual void pauseAnimationForTestingOnCompositor(const Element&, int id, do uble pauseTime);
55 55
56 virtual bool getAnimatedBoundingBox(FloatBox&, const AnimationEffect&, doubl e minValue, double maxValue) const; 56 virtual bool getAnimatedBoundingBox(FloatBox&, const AnimationEffect&, doubl e minValue, double maxValue) const;
57 protected: 57 protected:
58 CompositorAnimations() { } 58 CompositorAnimations() { }
59 59
60 private: 60 private:
61 static CompositorAnimations* instance(CompositorAnimations* newInstance) 61 static CompositorAnimations* instance(CompositorAnimations* newInstance)
62 { 62 {
63 static CompositorAnimations* instance = new CompositorAnimations(); 63 static CompositorAnimations* instance = new CompositorAnimations();
64 if (newInstance) { 64 if (newInstance) {
65 instance = newInstance; 65 instance = newInstance;
66 } 66 }
67 return instance; 67 return instance;
68 } 68 }
69 }; 69 };
70 70
71 } // namespace blink 71 } // namespace blink
72 72
73 #endif 73 #endif
OLDNEW
« no previous file with comments | « Source/core/animation/AnimationPlayer.cpp ('k') | Source/core/animation/CompositorAnimations.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698