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

Unified Diff: components/mus/common/gpu_service.h

Issue 2020293003: Use mus::MojoGpuMemoryBufferManager in mus::GpuService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/mus/common/gpu_memory_buffer_impl.cc ('k') | components/mus/common/gpu_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/common/gpu_service.h
diff --git a/components/mus/public/cpp/lib/gpu_service.h b/components/mus/common/gpu_service.h
similarity index 75%
rename from components/mus/public/cpp/lib/gpu_service.h
rename to components/mus/common/gpu_service.h
index 571a3537c14dd1c9be8b8ab2effff36afb8d5ae1..91be13f3d90cce73086c0f801cda3c15834b56be 100644
--- a/components/mus/public/cpp/lib/gpu_service.h
+++ b/components/mus/common/gpu_service.h
@@ -2,15 +2,17 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef COMPONENTS_MUS_PUBLIC_CPP_LIB_GPU_SERVICE_H_
-#define COMPONENTS_MUS_PUBLIC_CPP_LIB_GPU_SERVICE_H_
+#ifndef COMPONENTS_MUS_COMMON_GPU_SERVICE_H_
+#define COMPONENTS_MUS_COMMON_GPU_SERVICE_H_
#include <stdint.h>
#include <vector>
#include "base/macros.h"
+#include "base/synchronization/lock.h"
#include "base/synchronization/waitable_event.h"
#include "base/threading/thread.h"
+#include "components/mus/common/mus_common_export.h"
#include "gpu/ipc/client/gpu_channel_host.h"
namespace shell {
@@ -19,9 +21,9 @@ class Connector;
namespace mus {
-class GpuMemoryBufferManagerMus;
+class MojoGpuMemoryBufferManager;
-class GpuService : public gpu::GpuChannelHostFactory {
+class MUS_COMMON_EXPORT GpuService : public gpu::GpuChannelHostFactory {
public:
scoped_refptr<gpu::GpuChannelHost> EstablishGpuChannel(
shell::Connector* connector);
@@ -44,7 +46,10 @@ class GpuService : public gpu::GpuChannelHostFactory {
base::MessageLoop* main_message_loop_;
base::WaitableEvent shutdown_event_;
base::Thread io_thread_;
- std::unique_ptr<GpuMemoryBufferManagerMus> gpu_memory_buffer_manager_;
+ std::unique_ptr<MojoGpuMemoryBufferManager> gpu_memory_buffer_manager_;
+
+ // Lock for |gpu_channel_|.
+ base::Lock lock_;
scoped_refptr<gpu::GpuChannelHost> gpu_channel_;
DISALLOW_COPY_AND_ASSIGN(GpuService);
« no previous file with comments | « components/mus/common/gpu_memory_buffer_impl.cc ('k') | components/mus/common/gpu_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698