| 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 <public/WebFilterOperations.h> | 8 #include <public/WebFilterOperations.h> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 314 // is not available and the update rect will remain empty. | 314 // is not available and the update rect will remain empty. |
| 315 // Note this rect is in layer space (not content space). | 315 // Note this rect is in layer space (not content space). |
| 316 gfx::RectF m_updateRect; | 316 gfx::RectF m_updateRect; |
| 317 | 317 |
| 318 scoped_refptr<Layer> m_maskLayer; | 318 scoped_refptr<Layer> m_maskLayer; |
| 319 | 319 |
| 320 // Constructs a LayerImpl of the correct runtime type for this Layer type. | 320 // Constructs a LayerImpl of the correct runtime type for this Layer type. |
| 321 virtual scoped_ptr<LayerImpl> createLayerImpl(LayerTreeImpl* treeImpl); | 321 virtual scoped_ptr<LayerImpl> createLayerImpl(LayerTreeImpl* treeImpl); |
| 322 int m_layerId; | 322 int m_layerId; |
| 323 | 323 |
| 324 // When true, the layer is about to perform an update. Any commit requests |
| 325 // will be handled implcitly after the update completes. |
| 326 bool m_ignoreSetNeedsCommit; |
| 327 |
| 324 private: | 328 private: |
| 325 friend class base::RefCounted<Layer>; | 329 friend class base::RefCounted<Layer>; |
| 326 | 330 |
| 327 void setParent(Layer*); | 331 void setParent(Layer*); |
| 328 bool hasAncestor(Layer*) const; | 332 bool hasAncestor(Layer*) const; |
| 329 bool descendantIsFixedToContainerLayer() const; | 333 bool descendantIsFixedToContainerLayer() const; |
| 330 | 334 |
| 331 size_t numChildren() const { return m_children.size(); } | 335 size_t numChildren() const { return m_children.size(); } |
| 332 | 336 |
| 333 // Returns the index of the child or -1 if not found. | 337 // Returns the index of the child or -1 if not found. |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 396 WebKit::WebLayerScrollClient* m_layerScrollClient; | 400 WebKit::WebLayerScrollClient* m_layerScrollClient; |
| 397 | 401 |
| 398 DrawProperties<Layer, RenderSurface> m_drawProperties; | 402 DrawProperties<Layer, RenderSurface> m_drawProperties; |
| 399 }; | 403 }; |
| 400 | 404 |
| 401 void sortLayers(std::vector<scoped_refptr<Layer> >::iterator, std::vector<scoped
_refptr<Layer> >::iterator, void*); | 405 void sortLayers(std::vector<scoped_refptr<Layer> >::iterator, std::vector<scoped
_refptr<Layer> >::iterator, void*); |
| 402 | 406 |
| 403 } // namespace cc | 407 } // namespace cc |
| 404 | 408 |
| 405 #endif // CC_LAYER_H_ | 409 #endif // CC_LAYER_H_ |
| OLD | NEW |