OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 12 matching lines...) Expand all Loading... |
23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
24 */ | 24 */ |
25 | 25 |
26 #ifndef WebLayer_h | 26 #ifndef WebLayer_h |
27 #define WebLayer_h | 27 #define WebLayer_h |
28 | 28 |
29 #include "WebAnimation.h" | 29 #include "WebAnimation.h" |
30 #include "WebColor.h" | 30 #include "WebColor.h" |
31 #include "WebCommon.h" | 31 #include "WebCommon.h" |
32 #include "WebCompositingReasons.h" | 32 #include "WebCompositingReasons.h" |
| 33 #include "WebPassOwnPtr.h" |
33 #include "WebPoint.h" | 34 #include "WebPoint.h" |
34 #include "WebRect.h" | 35 #include "WebRect.h" |
35 #include "WebString.h" | 36 #include "WebString.h" |
36 #include "WebVector.h" | 37 #include "WebVector.h" |
37 | 38 |
38 class SkMatrix44; | 39 class SkMatrix44; |
39 class SkImageFilter; | 40 class SkImageFilter; |
40 | 41 |
41 namespace WebKit { | 42 namespace WebKit { |
42 class WebAnimationDelegate; | 43 class WebAnimationDelegate; |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 // Provides a bitfield that describe why this composited layer was created. | 131 // Provides a bitfield that describe why this composited layer was created. |
131 virtual void setCompositingReasons(WebCompositingReasons) = 0; | 132 virtual void setCompositingReasons(WebCompositingReasons) = 0; |
132 | 133 |
133 // An animation delegate is notified when animations are started and | 134 // An animation delegate is notified when animations are started and |
134 // stopped. The WebLayer does not take ownership of the delegate, and it is | 135 // stopped. The WebLayer does not take ownership of the delegate, and it is |
135 // the responsibility of the client to reset the layer's delegate before | 136 // the responsibility of the client to reset the layer's delegate before |
136 // deleting the delegate. | 137 // deleting the delegate. |
137 virtual void setAnimationDelegate(WebAnimationDelegate*) = 0; | 138 virtual void setAnimationDelegate(WebAnimationDelegate*) = 0; |
138 | 139 |
139 // Returns false if the animation cannot be added. | 140 // Returns false if the animation cannot be added. |
140 virtual bool addAnimation(WebAnimation*) = 0; | 141 virtual bool addAnimation(WebPassOwnPtr<WebAnimation>) = 0; |
141 | 142 |
142 // Removes all animations with the given id. | 143 // Removes all animations with the given id. |
143 virtual void removeAnimation(int animationId) = 0; | 144 virtual void removeAnimation(int animationId) = 0; |
144 | 145 |
145 // Removes all animations with the given id targeting the given property. | 146 // Removes all animations with the given id targeting the given property. |
146 virtual void removeAnimation(int animationId, WebAnimation::TargetProperty)
= 0; | 147 virtual void removeAnimation(int animationId, WebAnimation::TargetProperty)
= 0; |
147 | 148 |
148 // Pauses all animations with the given id. | 149 // Pauses all animations with the given id. |
149 virtual void pauseAnimation(int animationId, double timeOffset) = 0; | 150 virtual void pauseAnimation(int animationId, double timeOffset) = 0; |
150 | 151 |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
209 | 210 |
210 // True if the layer is not part of a tree attached to a WebLayerTreeView. | 211 // True if the layer is not part of a tree attached to a WebLayerTreeView. |
211 virtual bool isOrphan() const = 0; | 212 virtual bool isOrphan() const = 0; |
212 | 213 |
213 virtual void setWebLayerClient(WebLayerClient*) = 0; | 214 virtual void setWebLayerClient(WebLayerClient*) = 0; |
214 }; | 215 }; |
215 | 216 |
216 } // namespace WebKit | 217 } // namespace WebKit |
217 | 218 |
218 #endif // WebLayer_h | 219 #endif // WebLayer_h |
OLD | NEW |