OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef WebCompositorAnimation_h | 5 #ifndef WebCompositorAnimation_h |
6 #define WebCompositorAnimation_h | 6 #define WebCompositorAnimation_h |
7 | 7 |
8 #include "WebAnimation.h" | 8 #include "WebCommon.h" |
9 #include "WebNonCopyable.h" | |
jochen (gone - plz use gerrit)
2014/08/04 09:07:33
unused?
samli
2014/08/11 04:10:59
Done.
| |
10 #include "WebPrivateOwnPtr.h" | |
jochen (gone - plz use gerrit)
2014/08/04 09:07:33
also unused?
samli
2014/08/11 04:10:59
Done.
| |
11 | |
12 #if BLINK_IMPLEMENTATION | |
13 #include "wtf/Forward.h" | |
jochen (gone - plz use gerrit)
2014/08/04 09:07:33
same here
samli
2014/08/11 04:10:59
Done.
| |
14 #endif | |
15 | |
16 namespace blink { | |
17 class CCActiveAnimation; | |
jochen (gone - plz use gerrit)
2014/08/04 09:07:33
not needed
samli
2014/08/11 04:10:59
Done.
| |
18 } | |
19 | |
20 namespace blink { | |
21 | |
22 class WebCompositorAnimationCurve; | |
jochen (gone - plz use gerrit)
2014/08/04 09:07:33
not needed either
samli
2014/08/11 04:10:59
Done.
| |
23 | |
24 // A compositor driven animation. | |
25 class WebCompositorAnimation { | |
26 public: | |
27 enum TargetProperty { | |
28 TargetPropertyTransform = 0, | |
29 TargetPropertyOpacity, | |
30 TargetPropertyFilter, | |
31 TargetPropertyScrollOffset | |
32 }; | |
33 | |
34 virtual ~WebCompositorAnimation() { } | |
35 | |
36 // An id is effectively the animation's name, and it is not unique. | |
37 virtual int id() = 0; | |
38 | |
39 virtual TargetProperty targetProperty() const = 0; | |
40 | |
41 // This is the number of times that the animation will play. If this | |
42 // value is zero the animation will not play. If it is negative, then | |
43 // the animation will loop indefinitely. | |
44 virtual int iterations() const = 0; | |
45 virtual void setIterations(int) = 0; | |
46 | |
47 virtual double startTime() const = 0; | |
48 virtual void setStartTime(double monotonicTime) = 0; | |
49 | |
50 virtual double timeOffset() const = 0; | |
51 virtual void setTimeOffset(double monotonicTime) = 0; | |
52 | |
53 // If alternatesDirection is true, on odd numbered iterations we reverse the curve. | |
54 virtual bool alternatesDirection() const = 0; | |
55 virtual void setAlternatesDirection(bool) = 0; | |
56 }; | |
57 | |
58 } // namespace blink | |
9 | 59 |
10 #endif // WebCompositorAnimation_h | 60 #endif // WebCompositorAnimation_h |
OLD | NEW |