| OLD | NEW |
| 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 // Represents the browser side of the browser <--> renderer communication | 5 // Represents the browser side of the browser <--> renderer communication |
| 6 // channel. There will be one RenderProcessHost per renderer process. | 6 // channel. There will be one RenderProcessHost per renderer process. |
| 7 | 7 |
| 8 #include "content/browser/renderer_host/render_process_host_impl.h" | 8 #include "content/browser/renderer_host/render_process_host_impl.h" |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 685 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 696 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO); | 696 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO); |
| 697 scoped_refptr<base::SequencedTaskRunner> mojo_task_runner = | 697 scoped_refptr<base::SequencedTaskRunner> mojo_task_runner = |
| 698 BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO) | 698 BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO) |
| 699 ->task_runner(); | 699 ->task_runner(); |
| 700 if (ShouldUseMojoChannel()) { | 700 if (ShouldUseMojoChannel()) { |
| 701 VLOG(1) << "Mojo Channel is enabled on host"; | 701 VLOG(1) << "Mojo Channel is enabled on host"; |
| 702 if (!channel_mojo_host_) { | 702 if (!channel_mojo_host_) { |
| 703 channel_mojo_host_.reset(new IPC::ChannelMojoHost(mojo_task_runner)); | 703 channel_mojo_host_.reset(new IPC::ChannelMojoHost(mojo_task_runner)); |
| 704 } | 704 } |
| 705 | 705 |
| 706 return IPC::ChannelProxy::Create( | 706 return IPC::ChannelProxy::Create(IPC::ChannelMojo::CreateServerFactory( |
| 707 IPC::ChannelMojo::CreateServerFactory( | 707 channel_mojo_host_->channel_delegate(), |
| 708 channel_mojo_host_->channel_delegate(), channel_id), | 708 mojo_task_runner, channel_id), |
| 709 this, | 709 this, runner.get()); |
| 710 runner.get()); | |
| 711 } | 710 } |
| 712 | 711 |
| 713 return IPC::ChannelProxy::Create( | 712 return IPC::ChannelProxy::Create( |
| 714 channel_id, IPC::Channel::MODE_SERVER, this, runner.get()); | 713 channel_id, IPC::Channel::MODE_SERVER, this, runner.get()); |
| 715 } | 714 } |
| 716 | 715 |
| 717 void RenderProcessHostImpl::CreateMessageFilters() { | 716 void RenderProcessHostImpl::CreateMessageFilters() { |
| 718 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 717 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 719 const base::CommandLine& browser_command_line = | 718 const base::CommandLine& browser_command_line = |
| 720 *base::CommandLine::ForCurrentProcess(); | 719 *base::CommandLine::ForCurrentProcess(); |
| (...skipping 1753 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2474 if (worker_ref_count_ == 0) | 2473 if (worker_ref_count_ == 0) |
| 2475 Cleanup(); | 2474 Cleanup(); |
| 2476 } | 2475 } |
| 2477 | 2476 |
| 2478 void RenderProcessHostImpl::GetAudioOutputControllers( | 2477 void RenderProcessHostImpl::GetAudioOutputControllers( |
| 2479 const GetAudioOutputControllersCallback& callback) const { | 2478 const GetAudioOutputControllersCallback& callback) const { |
| 2480 audio_renderer_host()->GetOutputControllers(callback); | 2479 audio_renderer_host()->GetOutputControllers(callback); |
| 2481 } | 2480 } |
| 2482 | 2481 |
| 2483 } // namespace content | 2482 } // namespace content |
| OLD | NEW |