Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_PICTURE_LAYER_H_ | 5 #ifndef CC_PICTURE_LAYER_H_ |
| 6 #define CC_PICTURE_LAYER_H_ | 6 #define CC_PICTURE_LAYER_H_ |
| 7 | 7 |
| 8 #include "cc/contents_scaling_layer.h" | 8 #include "cc/contents_scaling_layer.h" |
| 9 #include "cc/layer.h" | 9 #include "cc/layer.h" |
| 10 #include "cc/picture_pile.h" | 10 #include "cc/picture_pile.h" |
| 11 #include "cc/occlusion_tracker.h" | 11 #include "cc/occlusion_tracker.h" |
| 12 | 12 |
| 13 namespace cc { | 13 namespace cc { |
| 14 | 14 |
| 15 class ContentLayerClient; | 15 class ContentLayerClient; |
| 16 class ResourceUpdateQueue; | 16 class ResourceUpdateQueue; |
| 17 struct RenderingStats; | 17 struct RenderingStats; |
| 18 | 18 |
| 19 class CC_EXPORT PictureLayer : public ContentsScalingLayer { | 19 class CC_EXPORT PictureLayer : public ContentsScalingLayer { |
| 20 public: | 20 public: |
|
danakj
2013/01/05 00:04:58
heh, should be 1 space in front of these.
enne (OOO)
2013/01/06 03:57:18
Done.
| |
| 21 static scoped_refptr<PictureLayer> create(ContentLayerClient*); | 21 static scoped_refptr<PictureLayer> create(ContentLayerClient*); |
| 22 | 22 |
| 23 void clearClient() { client_ = 0; } | 23 void clearClient() { client_ = 0; } |
| 24 | 24 |
| 25 // Implement Layer interface | 25 // Implement Layer interface |
| 26 virtual bool drawsContent() const OVERRIDE; | 26 virtual bool drawsContent() const OVERRIDE; |
| 27 virtual scoped_ptr<LayerImpl> createLayerImpl( | 27 virtual scoped_ptr<LayerImpl> createLayerImpl( |
| 28 LayerTreeImpl* treeImpl) OVERRIDE; | 28 LayerTreeImpl* treeImpl) OVERRIDE; |
| 29 virtual void setLayerTreeHost(LayerTreeHost*) OVERRIDE; | |
|
danakj
2013/01/05 00:04:58
variable name here please (cr style)
enne (OOO)
2013/01/06 03:57:18
Done.
| |
| 29 virtual void pushPropertiesTo(LayerImpl*) OVERRIDE; | 30 virtual void pushPropertiesTo(LayerImpl*) OVERRIDE; |
| 30 virtual void setNeedsDisplayRect(const gfx::RectF& layerRect) OVERRIDE; | 31 virtual void setNeedsDisplayRect(const gfx::RectF& layerRect) OVERRIDE; |
| 31 virtual void update(ResourceUpdateQueue&, const OcclusionTracker*, | 32 virtual void update(ResourceUpdateQueue&, const OcclusionTracker*, |
| 32 RenderingStats&) OVERRIDE; | 33 RenderingStats&) OVERRIDE; |
| 33 virtual void setIsMask(bool is_mask) OVERRIDE; | 34 virtual void setIsMask(bool is_mask) OVERRIDE; |
| 34 | 35 |
| 35 protected: | 36 protected: |
| 36 explicit PictureLayer(ContentLayerClient*); | 37 explicit PictureLayer(ContentLayerClient*); |
| 37 virtual ~PictureLayer(); | 38 virtual ~PictureLayer(); |
| 38 | 39 |
| 39 private: | 40 private: |
| 40 ContentLayerClient* client_; | 41 ContentLayerClient* client_; |
| 41 PicturePile pile_; | 42 PicturePile pile_; |
| 42 // Invalidation to use the next time update is called. | 43 // Invalidation to use the next time update is called. |
| 43 Region pending_invalidation_; | 44 Region pending_invalidation_; |
| 44 // Invalidation from the last time update was called. | 45 // Invalidation from the last time update was called. |
| 45 Region pile_invalidation_; | 46 Region pile_invalidation_; |
| 46 bool is_mask_; | 47 bool is_mask_; |
| 47 }; | 48 }; |
| 48 | 49 |
| 49 } // namespace cc | 50 } // namespace cc |
| 50 | 51 |
| 51 #endif // CC_PICTURE_LAYER_H_ | 52 #endif // CC_PICTURE_LAYER_H_ |
| OLD | NEW |