OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_LAYERS_SURFACE_LAYER_H_ | 5 #ifndef CC_LAYERS_SURFACE_LAYER_H_ |
6 #define CC_LAYERS_SURFACE_LAYER_H_ | 6 #define CC_LAYERS_SURFACE_LAYER_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "cc/cc_export.h" | 9 #include "cc/cc_export.h" |
10 #include "cc/layers/layer.h" | 10 #include "cc/layers/layer.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 return fallback_surface_info_; | 45 return fallback_surface_info_; |
46 } | 46 } |
47 | 47 |
48 protected: | 48 protected: |
49 explicit SurfaceLayer(scoped_refptr<SurfaceReferenceFactory> ref_factory); | 49 explicit SurfaceLayer(scoped_refptr<SurfaceReferenceFactory> ref_factory); |
50 bool HasDrawableContent() const override; | 50 bool HasDrawableContent() const override; |
51 | 51 |
52 private: | 52 private: |
53 ~SurfaceLayer() override; | 53 ~SurfaceLayer() override; |
54 void RemoveReference(base::Closure reference_returner); | 54 void RemoveReference(base::Closure reference_returner); |
| 55 void AddReferencedSurfaceId(const SurfaceInfo& surface_info); |
| 56 void RemoveReferencedSurfaceId(const SurfaceInfo& surface_info); |
55 | 57 |
56 SurfaceInfo primary_surface_info_; | 58 SurfaceInfo primary_surface_info_; |
57 base::Closure primary_reference_returner_; | 59 base::Closure primary_reference_returner_; |
58 | 60 |
59 SurfaceInfo fallback_surface_info_; | 61 SurfaceInfo fallback_surface_info_; |
60 base::Closure fallback_reference_returner_; | 62 base::Closure fallback_reference_returner_; |
61 | 63 |
62 scoped_refptr<SurfaceReferenceFactory> ref_factory_; | 64 scoped_refptr<SurfaceReferenceFactory> ref_factory_; |
63 bool stretch_content_to_fill_bounds_ = false; | 65 bool stretch_content_to_fill_bounds_ = false; |
64 | 66 |
65 DISALLOW_COPY_AND_ASSIGN(SurfaceLayer); | 67 DISALLOW_COPY_AND_ASSIGN(SurfaceLayer); |
66 }; | 68 }; |
67 | 69 |
68 } // namespace cc | 70 } // namespace cc |
69 | 71 |
70 #endif // CC_LAYERS_SURFACE_LAYER_H_ | 72 #endif // CC_LAYERS_SURFACE_LAYER_H_ |
OLD | NEW |