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

Side by Side Diff: content/common/gpu/gpu_channel.cc

Issue 6901146: Switch IPC::ChannelProxy to use MessageLoopProxy instead of MessageLoop. This allows us to remov... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « content/common/gpu/gpu_channel.h ('k') | content/common/gpu/gpu_channel_manager.h » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #if defined(OS_WIN) 5 #if defined(OS_WIN)
6 #include <windows.h> 6 #include <windows.h>
7 #endif 7 #endif
8 8
9 #include "content/common/gpu/gpu_channel.h" 9 #include "content/common/gpu/gpu_channel.h"
10 10
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 host_id, route_id)); 296 host_id, route_id));
297 router_.AddRoute(route_id, transport.get()); 297 router_.AddRoute(route_id, transport.get());
298 transport_textures_.AddWithID(transport.release(), route_id); 298 transport_textures_.AddWithID(transport.release(), route_id);
299 299
300 IPC::Message* msg = new GpuTransportTextureHostMsg_TransportTextureCreated( 300 IPC::Message* msg = new GpuTransportTextureHostMsg_TransportTextureCreated(
301 host_id, route_id); 301 host_id, route_id);
302 Send(msg); 302 Send(msg);
303 #endif 303 #endif
304 } 304 }
305 305
306 bool GpuChannel::Init(MessageLoop* io_message_loop, 306 bool GpuChannel::Init(base::MessageLoopProxy* io_message_loop,
307 base::WaitableEvent* shutdown_event) { 307 base::WaitableEvent* shutdown_event) {
308 // Check whether we're already initialized. 308 // Check whether we're already initialized.
309 if (channel_.get()) 309 if (channel_.get())
310 return true; 310 return true;
311 311
312 // Map renderer ID to a (single) channel to that process. 312 // Map renderer ID to a (single) channel to that process.
313 std::string channel_name = GetChannelName(); 313 std::string channel_name = GetChannelName();
314 channel_.reset(new IPC::SyncChannel( 314 channel_.reset(new IPC::SyncChannel(
315 channel_name, 315 channel_name,
316 IPC::Channel::MODE_SERVER, 316 IPC::Channel::MODE_SERVER,
(...skipping 11 matching lines...) Expand all
328 328
329 #if defined(OS_POSIX) 329 #if defined(OS_POSIX)
330 int GpuChannel::GetRendererFileDescriptor() { 330 int GpuChannel::GetRendererFileDescriptor() {
331 int fd = -1; 331 int fd = -1;
332 if (channel_.get()) { 332 if (channel_.get()) {
333 fd = channel_->GetClientFileDescriptor(); 333 fd = channel_->GetClientFileDescriptor();
334 } 334 }
335 return fd; 335 return fd;
336 } 336 }
337 #endif // defined(OS_POSIX) 337 #endif // defined(OS_POSIX)
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_channel.h ('k') | content/common/gpu/gpu_channel_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698