| OLD | NEW |
| 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 "services/ui/ws/gpu_service_proxy.h" | 5 #include "services/ui/ws/gpu_service_proxy.h" |
| 6 | 6 |
| 7 #include "base/memory/shared_memory.h" | 7 #include "base/memory/shared_memory.h" |
| 8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
| 9 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
| 10 #include "base/threading/thread_task_runner_handle.h" | 10 #include "base/threading/thread_task_runner_handle.h" |
| 11 #include "gpu/ipc/client/gpu_channel_host.h" | 11 #include "gpu/ipc/client/gpu_channel_host.h" |
| 12 #include "services/shell/public/cpp/connection.h" | 12 #include "services/service_manager/public/cpp/connection.h" |
| 13 #include "services/ui/ws/gpu_service_proxy_delegate.h" | 13 #include "services/ui/ws/gpu_service_proxy_delegate.h" |
| 14 #include "services/ui/ws/mus_gpu_memory_buffer_manager.h" | 14 #include "services/ui/ws/mus_gpu_memory_buffer_manager.h" |
| 15 | 15 |
| 16 namespace ui { | 16 namespace ui { |
| 17 namespace ws { | 17 namespace ws { |
| 18 | 18 |
| 19 namespace { | 19 namespace { |
| 20 | 20 |
| 21 const int32_t kInternalGpuChannelClientId = 1; | 21 const int32_t kInternalGpuChannelClientId = 1; |
| 22 const uint64_t kInternalGpuChannelClientTracingId = 1; | 22 const uint64_t kInternalGpuChannelClientTracingId = 1; |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 std::unique_ptr<base::SharedMemory> GpuServiceProxy::AllocateSharedMemory( | 120 std::unique_ptr<base::SharedMemory> GpuServiceProxy::AllocateSharedMemory( |
| 121 size_t size) { | 121 size_t size) { |
| 122 std::unique_ptr<base::SharedMemory> shm(new base::SharedMemory()); | 122 std::unique_ptr<base::SharedMemory> shm(new base::SharedMemory()); |
| 123 if (!shm->CreateAnonymous(size)) | 123 if (!shm->CreateAnonymous(size)) |
| 124 shm.reset(); | 124 shm.reset(); |
| 125 return shm; | 125 return shm; |
| 126 } | 126 } |
| 127 | 127 |
| 128 } // namespace ws | 128 } // namespace ws |
| 129 } // namespace ui | 129 } // namespace ui |
| OLD | NEW |