| OLD | NEW | 
|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 5 #ifndef SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 
| 6 #define SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 6 #define SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 
| 7 | 7 | 
| 8 #include <memory> | 8 #include <memory> | 
| 9 #include <vector> | 9 #include <vector> | 
| 10 | 10 | 
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 73   void DidReceiveCompositorFrameAck() override; | 73   void DidReceiveCompositorFrameAck() override; | 
| 74   void OnBeginFrame(const cc::BeginFrameArgs& args) override; | 74   void OnBeginFrame(const cc::BeginFrameArgs& args) override; | 
| 75   void ReclaimResources(const cc::ReturnedResourceArray& resources) override; | 75   void ReclaimResources(const cc::ReturnedResourceArray& resources) override; | 
| 76   void WillDrawSurface() override; | 76   void WillDrawSurface() override; | 
| 77 | 77 | 
| 78   void OnClientConnectionLost(); | 78   void OnClientConnectionLost(); | 
| 79   void OnPrivateConnectionLost(); | 79   void OnPrivateConnectionLost(); | 
| 80 | 80 | 
| 81   DisplayCompositor* const display_compositor_; | 81   DisplayCompositor* const display_compositor_; | 
| 82 | 82 | 
|  | 83   // GpuCompositorFrameSink holds a Display and its BeginFrameSource if it | 
|  | 84   // created with non-null gpu::SurfaceHandle. In the window server, the display | 
|  | 85   // root window's CompositorFrameSink will have a valid gpu::SurfaceHandle. | 
|  | 86   std::unique_ptr<cc::Display> display_; | 
|  | 87   std::unique_ptr<cc::BeginFrameSource> display_begin_frame_source_; | 
| 83   cc::CompositorFrameSinkSupport support_; | 88   cc::CompositorFrameSinkSupport support_; | 
| 84 | 89 | 
| 85   // Track the surface references for the surface corresponding to this | 90   // Track the surface references for the surface corresponding to this | 
| 86   // compositor frame sink. | 91   // compositor frame sink. | 
| 87   cc::ReferencedSurfaceTracker surface_tracker_; | 92   cc::ReferencedSurfaceTracker surface_tracker_; | 
| 88 | 93 | 
| 89   bool client_connection_lost_ = false; | 94   bool client_connection_lost_ = false; | 
| 90   bool private_connection_lost_ = false; | 95   bool private_connection_lost_ = false; | 
| 91 | 96 | 
| 92   cc::mojom::MojoCompositorFrameSinkClientPtr client_; | 97   cc::mojom::MojoCompositorFrameSinkClientPtr client_; | 
| 93   mojo::Binding<cc::mojom::MojoCompositorFrameSink> binding_; | 98   mojo::Binding<cc::mojom::MojoCompositorFrameSink> binding_; | 
| 94   mojo::Binding<cc::mojom::MojoCompositorFrameSinkPrivate> | 99   mojo::Binding<cc::mojom::MojoCompositorFrameSinkPrivate> | 
| 95       compositor_frame_sink_private_binding_; | 100       compositor_frame_sink_private_binding_; | 
| 96   mojo::Binding<cc::mojom::DisplayPrivate> display_private_binding_; | 101   mojo::Binding<cc::mojom::DisplayPrivate> display_private_binding_; | 
| 97 | 102 | 
| 98   DISALLOW_COPY_AND_ASSIGN(GpuCompositorFrameSink); | 103   DISALLOW_COPY_AND_ASSIGN(GpuCompositorFrameSink); | 
| 99 }; | 104 }; | 
| 100 | 105 | 
| 101 }  // namespace ui | 106 }  // namespace ui | 
| 102 | 107 | 
| 103 #endif  // SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 108 #endif  // SERVICES_UI_SURFACES_GPU_COMPOSITOR_FRAME_SINK_H_ | 
| OLD | NEW | 
|---|