OLD | NEW |
1 // Copyright 2010 The Chromium Authors. All rights reserved. | 1 // Copyright 2010 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 CC_LAYER_H_ | 5 #ifndef CC_LAYER_H_ |
6 #define CC_LAYER_H_ | 6 #define CC_LAYER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 // Returns the index of the child or -1 if not found. | 333 // Returns the index of the child or -1 if not found. |
334 int indexOfChild(const Layer*); | 334 int indexOfChild(const Layer*); |
335 | 335 |
336 // This should only be called from removeFromParent. | 336 // This should only be called from removeFromParent. |
337 void removeChild(Layer*); | 337 void removeChild(Layer*); |
338 | 338 |
339 // LayerAnimationValueObserver implementation. | 339 // LayerAnimationValueObserver implementation. |
340 virtual void OnOpacityAnimated(float) OVERRIDE; | 340 virtual void OnOpacityAnimated(float) OVERRIDE; |
341 virtual void OnTransformAnimated(const gfx::Transform&) OVERRIDE; | 341 virtual void OnTransformAnimated(const gfx::Transform&) OVERRIDE; |
342 virtual bool IsActive() const OVERRIDE; | 342 virtual bool IsActive() const OVERRIDE; |
| 343 virtual bool IsOrphaned() const OVERRIDE; |
343 | 344 |
344 LayerList m_children; | 345 LayerList m_children; |
345 Layer* m_parent; | 346 Layer* m_parent; |
346 | 347 |
347 // Layer instances have a weak pointer to their LayerTreeHost. | 348 // Layer instances have a weak pointer to their LayerTreeHost. |
348 // This pointer value is nil when a Layer is not in a tree and is | 349 // This pointer value is nil when a Layer is not in a tree and is |
349 // updated via setLayerTreeHost() if a layer moves between trees. | 350 // updated via setLayerTreeHost() if a layer moves between trees. |
350 LayerTreeHost* m_layerTreeHost; | 351 LayerTreeHost* m_layerTreeHost; |
351 | 352 |
352 ObserverList<LayerAnimationEventObserver> m_layerAnimationObservers; | 353 ObserverList<LayerAnimationEventObserver> m_layerAnimationObservers; |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
400 WebKit::WebLayerScrollClient* m_layerScrollClient; | 401 WebKit::WebLayerScrollClient* m_layerScrollClient; |
401 | 402 |
402 DrawProperties<Layer, RenderSurface> m_drawProperties; | 403 DrawProperties<Layer, RenderSurface> m_drawProperties; |
403 }; | 404 }; |
404 | 405 |
405 void sortLayers(std::vector<scoped_refptr<Layer> >::iterator, std::vector<scoped
_refptr<Layer> >::iterator, void*); | 406 void sortLayers(std::vector<scoped_refptr<Layer> >::iterator, std::vector<scoped
_refptr<Layer> >::iterator, void*); |
406 | 407 |
407 } // namespace cc | 408 } // namespace cc |
408 | 409 |
409 #endif // CC_LAYER_H_ | 410 #endif // CC_LAYER_H_ |
OLD | NEW |