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

Unified Diff: services/ui/gpu/gpu_service_internal.cc

Issue 2534663002: mus: Move MusGpuMemoryBufferManager into common. (Closed)
Patch Set: . Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « services/ui/gpu/gpu_service_internal.h ('k') | services/ui/surfaces/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/gpu/gpu_service_internal.cc
diff --git a/services/ui/gpu/gpu_service_internal.cc b/services/ui/gpu/gpu_service_internal.cc
index f099c910bf1c3a9f266a6da8c20b80e15e6f7cf4..5681fc0987246dfe92d0767b361510772cc616a9 100644
--- a/services/ui/gpu/gpu_service_internal.cc
+++ b/services/ui/gpu/gpu_service_internal.cc
@@ -27,8 +27,8 @@
#include "media/gpu/ipc/service/gpu_video_encode_accelerator.h"
#include "media/gpu/ipc/service/media_gpu_channel_manager.h"
#include "mojo/public/cpp/bindings/strong_binding.h"
+#include "services/ui/common/mus_gpu_memory_buffer_manager.h"
#include "services/ui/surfaces/display_compositor.h"
-#include "services/ui/surfaces/mus_gpu_memory_buffer_manager.h"
#include "ui/gl/gl_implementation.h"
#include "ui/gl/gl_switches.h"
#include "ui/gl/gpu_switching_manager.h"
@@ -114,14 +114,13 @@ void GpuServiceInternal::CreateDisplayCompositorOnCompositorThread(
cc::mojom::DisplayCompositorRequest request,
cc::mojom::DisplayCompositorClientPtrInfo client_info) {
DCHECK(compositor_runner_->BelongsToCurrentThread());
- mojom::GpuServiceInternalPtr gpu_service_ptr;
- gpu_service_ptr.Bind(std::move(gpu_service_info));
+ gpu_internal_.Bind(std::move(gpu_service_info));
cc::mojom::DisplayCompositorClientPtr client_ptr;
client_ptr.Bind(std::move(client_info));
std::unique_ptr<MusGpuMemoryBufferManager> gpu_memory_buffer_manager =
- base::MakeUnique<MusGpuMemoryBufferManager>(std::move(gpu_service_ptr),
+ base::MakeUnique<MusGpuMemoryBufferManager>(gpu_internal_.get(),
1 /* client_id */);
// |gpu_memory_buffer_factory_| is null in tests.
gpu::ImageFactory* image_factory =
@@ -146,6 +145,7 @@ void GpuServiceInternal::DestroyDisplayCompositor() {
void GpuServiceInternal::DestroyDisplayCompositorOnCompositorThread() {
display_compositor_.reset();
+ gpu_internal_.reset();
}
void GpuServiceInternal::DidCreateOffscreenContext(const GURL& active_url) {
« no previous file with comments | « services/ui/gpu/gpu_service_internal.h ('k') | services/ui/surfaces/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698