Index: cc/layers/layer.h |
diff --git a/cc/layers/layer.h b/cc/layers/layer.h |
index 61ef3f8c3ac701b0b89f87fc74886a2189665774..25893717c9d642dd5ec4587921efe17b700bf8b7 100644 |
--- a/cc/layers/layer.h |
+++ b/cc/layers/layer.h |
@@ -254,9 +254,7 @@ class CC_EXPORT Layer : public base::RefCounted<Layer>, |
draw_properties_.render_target->render_surface()); |
return draw_properties_.render_target; |
} |
- RenderSurface* render_surface() const { |
- return draw_properties_.render_surface.get(); |
- } |
+ RenderSurface* render_surface() const { return render_surface_.get(); } |
danakj
2014/08/26 18:06:13
nit: can you move this out of the middle of the dr
awoloszyn
2014/08/28 19:31:42
Done.
|
int num_unclipped_descendants() const { |
return draw_properties_.num_unclipped_descendants; |
} |
@@ -376,6 +374,11 @@ class CC_EXPORT Layer : public base::RefCounted<Layer>, |
void CreateRenderSurface(); |
void ClearRenderSurface(); |
+ |
+ void SetShouldHaveRenderSurface(bool should_have); |
+ void SetRenderSurfaceActive(bool active); |
danakj
2014/08/26 18:06:13
Should we get rid of {Create,Clear}RenderSurface t
awoloszyn
2014/08/28 19:31:43
This one is a bit tricky. RenderSurfaces get destr
|
+ bool ShouldHaveRenderSurface() { return should_have_render_surface_; } |
+ |
void ClearRenderSurfaceLayerList(); |
// The contents scale converts from logical, non-page-scaled pixels to target |
@@ -608,6 +611,7 @@ class CC_EXPORT Layer : public base::RefCounted<Layer>, |
bool draw_checkerboard_for_missing_tiles_ : 1; |
bool force_render_surface_ : 1; |
bool transform_is_invertible_ : 1; |
+ bool should_have_render_surface_ : 1; |
Region non_fast_scrollable_region_; |
Region touch_event_handler_region_; |
gfx::PointF position_; |
@@ -641,6 +645,7 @@ class CC_EXPORT Layer : public base::RefCounted<Layer>, |
DrawProperties<Layer> draw_properties_; |
PaintProperties paint_properties_; |
+ scoped_ptr<RenderSurface> render_surface_; |
DISALLOW_COPY_AND_ASSIGN(Layer); |
}; |