Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(132)

Side by Side Diff: ui/aura/mus/window_port_mus.cc

Issue 2903853002: Make RendererCompositorFrameSink derive from ClientCompositorFrameSink (Closed)
Patch Set: Add comments Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « content/renderer/mus/renderer_window_tree_client.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "ui/aura/mus/window_port_mus.h" 5 #include "ui/aura/mus/window_port_mus.h"
6 6
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "ui/aura/client/aura_constants.h" 8 #include "ui/aura/client/aura_constants.h"
9 #include "ui/aura/client/transient_window_client.h" 9 #include "ui/aura/client/transient_window_client.h"
10 #include "ui/aura/mus/client_surface_embedder.h" 10 #include "ui/aura/mus/client_surface_embedder.h"
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 scoped_refptr<cc::ContextProvider> context_provider, 98 scoped_refptr<cc::ContextProvider> context_provider,
99 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager) { 99 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager) {
100 cc::mojom::MojoCompositorFrameSinkPtrInfo sink_info; 100 cc::mojom::MojoCompositorFrameSinkPtrInfo sink_info;
101 cc::mojom::MojoCompositorFrameSinkRequest sink_request = 101 cc::mojom::MojoCompositorFrameSinkRequest sink_request =
102 mojo::MakeRequest(&sink_info); 102 mojo::MakeRequest(&sink_info);
103 cc::mojom::MojoCompositorFrameSinkClientPtr client; 103 cc::mojom::MojoCompositorFrameSinkClientPtr client;
104 cc::mojom::MojoCompositorFrameSinkClientRequest client_request = 104 cc::mojom::MojoCompositorFrameSinkClientRequest client_request =
105 mojo::MakeRequest(&client); 105 mojo::MakeRequest(&client);
106 constexpr bool enable_surface_synchronization = true; 106 constexpr bool enable_surface_synchronization = true;
107 auto compositor_frame_sink = base::MakeUnique<viz::ClientCompositorFrameSink>( 107 auto compositor_frame_sink = base::MakeUnique<viz::ClientCompositorFrameSink>(
108 std::move(context_provider), gpu_memory_buffer_manager, 108 std::move(context_provider), nullptr /* worker_context_provider */,
109 std::move(sink_info), std::move(client_request), 109 gpu_memory_buffer_manager, nullptr /* shared_bitmap_manager */,
110 enable_surface_synchronization); 110 nullptr /* synthetic_begin_frame_source */, std::move(sink_info),
111 std::move(client_request), enable_surface_synchronization);
111 window_tree_client_->AttachCompositorFrameSink( 112 window_tree_client_->AttachCompositorFrameSink(
112 server_id(), std::move(sink_request), std::move(client)); 113 server_id(), std::move(sink_request), std::move(client));
113 return std::move(compositor_frame_sink); 114 return std::move(compositor_frame_sink);
114 } 115 }
115 116
116 WindowPortMus::ServerChangeIdType WindowPortMus::ScheduleChange( 117 WindowPortMus::ServerChangeIdType WindowPortMus::ScheduleChange(
117 const ServerChangeType type, 118 const ServerChangeType type,
118 const ServerChangeData& data) { 119 const ServerChangeData& data) {
119 ServerChange change; 120 ServerChange change;
120 change.type = type; 121 change.type = type;
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after
527 if (!client_surface_embedder_) { 528 if (!client_surface_embedder_) {
528 client_surface_embedder_ = base::MakeUnique<ClientSurfaceEmbedder>( 529 client_surface_embedder_ = base::MakeUnique<ClientSurfaceEmbedder>(
529 window_, window_tree_client_->normal_client_area_insets_); 530 window_, window_tree_client_->normal_client_area_insets_);
530 } 531 }
531 532
532 client_surface_embedder_->SetPrimarySurfaceInfo(primary_surface_info_); 533 client_surface_embedder_->SetPrimarySurfaceInfo(primary_surface_info_);
533 client_surface_embedder_->SetFallbackSurfaceInfo(fallback_surface_info_); 534 client_surface_embedder_->SetFallbackSurfaceInfo(fallback_surface_info_);
534 } 535 }
535 536
536 } // namespace aura 537 } // namespace aura
OLDNEW
« no previous file with comments | « content/renderer/mus/renderer_window_tree_client.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698