| Index: cc/surfaces/surface.h
|
| diff --git a/cc/surfaces/surface.h b/cc/surfaces/surface.h
|
| index 9036d856b3b010a0f6c36e2c8be8cfa47eca4010..301329bcae83ab889c55c4ab1c405206596e145e 100644
|
| --- a/cc/surfaces/surface.h
|
| +++ b/cc/surfaces/surface.h
|
| @@ -17,6 +17,7 @@
|
| #include "base/callback.h"
|
| #include "base/macros.h"
|
| #include "base/memory/weak_ptr.h"
|
| +#include "base/optional.h"
|
| #include "cc/output/copy_output_request.h"
|
| #include "cc/quads/render_pass_id.h"
|
| #include "cc/surfaces/frame_sink_id.h"
|
| @@ -89,18 +90,20 @@ class CC_SURFACES_EXPORT Surface {
|
| return referenced_surfaces_;
|
| }
|
|
|
| + bool HasFrame() const { return current_frame_.has_value(); }
|
| +
|
| bool destroyed() const { return destroyed_; }
|
| void set_destroyed(bool destroyed) { destroyed_ = destroyed; }
|
|
|
| private:
|
| - void UnrefFrameResources(DelegatedFrameData* frame_data);
|
| + void UnrefFrameResources(const CompositorFrame& frame_data);
|
| void ClearCopyRequests();
|
|
|
| SurfaceId surface_id_;
|
| SurfaceId previous_frame_surface_id_;
|
| base::WeakPtr<SurfaceFactory> factory_;
|
| // TODO(jamesr): Support multiple frames in flight.
|
| - CompositorFrame current_frame_;
|
| + base::Optional<CompositorFrame> current_frame_;
|
| int frame_index_;
|
| bool destroyed_;
|
| std::vector<SurfaceSequence> destruction_dependencies_;
|
|
|