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

Side by Side Diff: content/gpu/gpu_child_thread.cc

Issue 2109483002: Remove MojoApplication[Host] & ApplicationSetup. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@u2
Patch Set: . Created 4 years, 5 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/content_common_mojo_bindings.gyp ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/gpu/gpu_child_thread.h" 5 #include "content/gpu/gpu_child_thread.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 builder.AddStartupFilter( 128 builder.AddStartupFilter(
129 new GpuMemoryBufferMessageFilter(gpu_memory_buffer_factory)); 129 new GpuMemoryBufferMessageFilter(gpu_memory_buffer_factory));
130 130
131 #if defined(USE_OZONE) 131 #if defined(USE_OZONE)
132 IPC::MessageFilter* message_filter = ui::OzonePlatform::GetInstance() 132 IPC::MessageFilter* message_filter = ui::OzonePlatform::GetInstance()
133 ->GetGpuPlatformSupport() 133 ->GetGpuPlatformSupport()
134 ->GetMessageFilter(); 134 ->GetMessageFilter();
135 if (message_filter) 135 if (message_filter)
136 builder.AddStartupFilter(message_filter); 136 builder.AddStartupFilter(message_filter);
137 #endif 137 #endif
138 builder.UseMojoShellConnection(true);
139 138
140 return builder.Build(); 139 return builder.Build();
141 } 140 }
142 141
143 } // namespace 142 } // namespace
144 143
145 // static 144 // static
146 GpuChildThread* GpuChildThread::current() { 145 GpuChildThread* GpuChildThread::current() {
147 return g_lazy_tls.Pointer()->Get(); 146 return g_lazy_tls.Pointer()->Get();
148 } 147 }
(...skipping 19 matching lines...) Expand all
168 } 167 }
169 168
170 GpuChildThread::GpuChildThread( 169 GpuChildThread::GpuChildThread(
171 const gpu::GpuPreferences& gpu_preferences, 170 const gpu::GpuPreferences& gpu_preferences,
172 const InProcessChildThreadParams& params, 171 const InProcessChildThreadParams& params,
173 gpu::GpuMemoryBufferFactory* gpu_memory_buffer_factory) 172 gpu::GpuMemoryBufferFactory* gpu_memory_buffer_factory)
174 : ChildThreadImpl(ChildThreadImpl::Options::Builder() 173 : ChildThreadImpl(ChildThreadImpl::Options::Builder()
175 .InBrowserProcess(params) 174 .InBrowserProcess(params)
176 .AddStartupFilter(new GpuMemoryBufferMessageFilter( 175 .AddStartupFilter(new GpuMemoryBufferMessageFilter(
177 gpu_memory_buffer_factory)) 176 gpu_memory_buffer_factory))
178 .UseMojoShellConnection(true)
179 .Build()), 177 .Build()),
180 gpu_preferences_(gpu_preferences), 178 gpu_preferences_(gpu_preferences),
181 dead_on_arrival_(false), 179 dead_on_arrival_(false),
182 in_browser_process_(true), 180 in_browser_process_(true),
183 gpu_memory_buffer_factory_(gpu_memory_buffer_factory) { 181 gpu_memory_buffer_factory_(gpu_memory_buffer_factory) {
184 #if defined(OS_WIN) 182 #if defined(OS_WIN)
185 target_services_ = NULL; 183 target_services_ = NULL;
186 #endif 184 #endif
187 DCHECK(base::CommandLine::ForCurrentProcess()->HasSwitch( 185 DCHECK(base::CommandLine::ForCurrentProcess()->HasSwitch(
188 switches::kSingleProcess) || 186 switches::kSingleProcess) ||
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
572 570
573 void GpuChildThread::BindProcessControlRequest( 571 void GpuChildThread::BindProcessControlRequest(
574 mojo::InterfaceRequest<mojom::ProcessControl> request) { 572 mojo::InterfaceRequest<mojom::ProcessControl> request) {
575 DVLOG(1) << "GPU: Binding ProcessControl request"; 573 DVLOG(1) << "GPU: Binding ProcessControl request";
576 DCHECK(process_control_); 574 DCHECK(process_control_);
577 process_control_bindings_.AddBinding(process_control_.get(), 575 process_control_bindings_.AddBinding(process_control_.get(),
578 std::move(request)); 576 std::move(request));
579 } 577 }
580 578
581 } // namespace content 579 } // namespace content
OLDNEW
« no previous file with comments | « content/content_common_mojo_bindings.gyp ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698