| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/browser/frame_host/render_frame_host_impl.h" | 5 #include "content/browser/frame_host/render_frame_host_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 2253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2264 // which shuts down Mojo). Hence, passing that MediaStreamManager instance | 2264 // which shuts down Mojo). Hence, passing that MediaStreamManager instance |
| 2265 // as a raw pointer here is safe. | 2265 // as a raw pointer here is safe. |
| 2266 MediaStreamManager* media_stream_manager = | 2266 MediaStreamManager* media_stream_manager = |
| 2267 BrowserMainLoop::GetInstance()->media_stream_manager(); | 2267 BrowserMainLoop::GetInstance()->media_stream_manager(); |
| 2268 GetInterfaceRegistry()->AddInterface( | 2268 GetInterfaceRegistry()->AddInterface( |
| 2269 base::Bind(&MediaDevicesDispatcherHost::Create, GetProcess()->GetID(), | 2269 base::Bind(&MediaDevicesDispatcherHost::Create, GetProcess()->GetID(), |
| 2270 GetRoutingID(), GetProcess() | 2270 GetRoutingID(), GetProcess() |
| 2271 ->GetBrowserContext() | 2271 ->GetBrowserContext() |
| 2272 ->GetResourceContext() | 2272 ->GetResourceContext() |
| 2273 ->GetMediaDeviceIDSalt(), | 2273 ->GetMediaDeviceIDSalt(), |
| 2274 base::Unretained(media_stream_manager), | 2274 base::Unretained(media_stream_manager)), |
| 2275 base::CommandLine::ForCurrentProcess()->HasSwitch( | |
| 2276 switches::kUseFakeUIForMediaStream)), | |
| 2277 BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)); | 2275 BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)); |
| 2278 } | 2276 } |
| 2279 #endif | 2277 #endif |
| 2280 | 2278 |
| 2281 GetContentClient()->browser()->RegisterRenderFrameMojoInterfaces( | 2279 GetContentClient()->browser()->RegisterRenderFrameMojoInterfaces( |
| 2282 GetInterfaceRegistry(), this); | 2280 GetInterfaceRegistry(), this); |
| 2283 } | 2281 } |
| 2284 | 2282 |
| 2285 void RenderFrameHostImpl::ResetWaitingState() { | 2283 void RenderFrameHostImpl::ResetWaitingState() { |
| 2286 DCHECK(is_active()); | 2284 DCHECK(is_active()); |
| (...skipping 900 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3187 web_bluetooth_service_->SetClientConnectionErrorHandler(base::Bind( | 3185 web_bluetooth_service_->SetClientConnectionErrorHandler(base::Bind( |
| 3188 &RenderFrameHostImpl::DeleteWebBluetoothService, base::Unretained(this))); | 3186 &RenderFrameHostImpl::DeleteWebBluetoothService, base::Unretained(this))); |
| 3189 return web_bluetooth_service_.get(); | 3187 return web_bluetooth_service_.get(); |
| 3190 } | 3188 } |
| 3191 | 3189 |
| 3192 void RenderFrameHostImpl::DeleteWebBluetoothService() { | 3190 void RenderFrameHostImpl::DeleteWebBluetoothService() { |
| 3193 web_bluetooth_service_.reset(); | 3191 web_bluetooth_service_.reset(); |
| 3194 } | 3192 } |
| 3195 | 3193 |
| 3196 } // namespace content | 3194 } // namespace content |
| OLD | NEW |