Chromium Code Reviews| Index: android_webview/browser/surfaces_instance.h |
| diff --git a/android_webview/browser/surfaces_instance.h b/android_webview/browser/surfaces_instance.h |
| index 9ed6557dc63a32c0a1a954a3e12ba02ad0f025d6..c4a1396974345c1bf5d499d7817f072d03f32220 100644 |
| --- a/android_webview/browser/surfaces_instance.h |
| +++ b/android_webview/browser/surfaces_instance.h |
| @@ -9,15 +9,15 @@ |
| #include <vector> |
| #include "base/memory/ref_counted.h" |
| +#include "cc/surfaces/compositor_frame_sink_support_client.h" |
| #include "cc/surfaces/display_client.h" |
| #include "cc/surfaces/frame_sink_id.h" |
| #include "cc/surfaces/surface_factory_client.h" |
| #include "cc/surfaces/surface_id.h" |
| namespace cc { |
| -class Display; |
| +class CompositorFrameSinkSupport; |
| class SurfaceIdAllocator; |
| -class SurfaceFactory; |
| class SurfaceManager; |
| } |
| @@ -32,8 +32,7 @@ namespace android_webview { |
| class ParentOutputSurface; |
| class SurfacesInstance : public base::RefCounted<SurfacesInstance>, |
| - public cc::DisplayClient, |
| - public cc::SurfaceFactoryClient { |
| + public cc::CompositorFrameSinkSupportClient { |
| public: |
| static scoped_refptr<SurfacesInstance> GetOrCreateInstance(); |
| @@ -55,28 +54,22 @@ class SurfacesInstance : public base::RefCounted<SurfacesInstance>, |
| SurfacesInstance(); |
| ~SurfacesInstance() override; |
| - // cc::DisplayClient overrides. |
| - void DisplayOutputSurfaceLost() override; |
| - void DisplayWillDrawAndSwap( |
| - bool will_draw_and_swap, |
| - const cc::RenderPassList& render_passes) override {} |
| - void DisplayDidDrawAndSwap() override {} |
| - |
| - // cc::SurfaceFactoryClient implementation. |
| - void ReturnResources(const cc::ReturnedResourceArray& resources) override; |
| - void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; |
| - |
| void SetEmptyRootFrame(); |
| + // cc::CompositorFrameSinkSupport implementation. |
|
boliu
2017/01/24 17:41:50
CompositorFrameSinkSupportClient
Saman Sami
2017/01/24 17:44:57
Done.
|
| + void DidReceiveCompositorFrameAck() override {} |
|
boliu
2017/01/24 17:41:50
there is no need to override methods that are no-o
Saman Sami
2017/01/24 17:44:57
It's a pure virtual in the parent.
boliu
2017/01/24 17:50:57
Oh oops, misread. Then the question is why are the
|
| + void OnBeginFrame(const cc::BeginFrameArgs& args) override {} |
| + void WillDrawSurface() override {} |
| + void ReclaimResources(const cc::ReturnedResourceArray& resources) override; |
| + void DisplayOutputSurfaceLost() override; |
| + |
| uint32_t next_client_id_; |
| cc::FrameSinkId frame_sink_id_; |
| std::unique_ptr<cc::SurfaceManager> surface_manager_; |
| - std::unique_ptr<cc::BeginFrameSource> begin_frame_source_; |
| - std::unique_ptr<cc::Display> display_; |
| std::unique_ptr<cc::SurfaceIdAllocator> surface_id_allocator_; |
| - std::unique_ptr<cc::SurfaceFactory> surface_factory_; |
| + std::unique_ptr<cc::CompositorFrameSinkSupport> support_; |
| cc::LocalFrameId root_id_; |
| std::vector<cc::SurfaceId> child_ids_; |