| 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 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 #endif | 100 #endif |
| 101 #endif | 101 #endif |
| 102 | 102 |
| 103 #if defined(OS_MACOSX) | 103 #if defined(OS_MACOSX) |
| 104 #include "content/browser/frame_host/popup_menu_helper_mac.h" | 104 #include "content/browser/frame_host/popup_menu_helper_mac.h" |
| 105 #endif | 105 #endif |
| 106 | 106 |
| 107 #if defined(ENABLE_WEBVR) | 107 #if defined(ENABLE_WEBVR) |
| 108 #include "base/command_line.h" | 108 #include "base/command_line.h" |
| 109 #include "content/public/common/content_switches.h" | 109 #include "content/public/common/content_switches.h" |
| 110 #include "device/vr/vr_device_manager.h" // nogncheck | 110 #include "device/vr/vr_service_impl.h" // nogncheck |
| 111 #endif | 111 #endif |
| 112 | 112 |
| 113 using base::TimeDelta; | 113 using base::TimeDelta; |
| 114 | 114 |
| 115 namespace content { | 115 namespace content { |
| 116 | 116 |
| 117 namespace { | 117 namespace { |
| 118 | 118 |
| 119 // The next value to use for the accessibility reset token. | 119 // The next value to use for the accessibility reset token. |
| 120 int g_next_accessibility_reset_token = 1; | 120 int g_next_accessibility_reset_token = 1; |
| (...skipping 1994 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2115 base::Bind(&CreateMediaServiceFactory, | 2115 base::Bind(&CreateMediaServiceFactory, |
| 2116 GetProcess()->GetBrowserContext(), this)); | 2116 GetProcess()->GetBrowserContext(), this)); |
| 2117 #endif // defined(MOJO_SHELL_CLIENT) | 2117 #endif // defined(MOJO_SHELL_CLIENT) |
| 2118 | 2118 |
| 2119 #if defined(ENABLE_WEBVR) | 2119 #if defined(ENABLE_WEBVR) |
| 2120 const base::CommandLine& browser_command_line = | 2120 const base::CommandLine& browser_command_line = |
| 2121 *base::CommandLine::ForCurrentProcess(); | 2121 *base::CommandLine::ForCurrentProcess(); |
| 2122 | 2122 |
| 2123 if (browser_command_line.HasSwitch(switches::kEnableWebVR)) { | 2123 if (browser_command_line.HasSwitch(switches::kEnableWebVR)) { |
| 2124 GetInterfaceRegistry()->AddInterface<device::VRService>( | 2124 GetInterfaceRegistry()->AddInterface<device::VRService>( |
| 2125 base::Bind(&device::VRDeviceManager::BindRequest)); | 2125 base::Bind(&device::VRServiceImpl::BindRequest)); |
| 2126 } | 2126 } |
| 2127 #endif | 2127 #endif |
| 2128 | 2128 |
| 2129 GetContentClient()->browser()->RegisterRenderFrameMojoInterfaces( | 2129 GetContentClient()->browser()->RegisterRenderFrameMojoInterfaces( |
| 2130 GetInterfaceRegistry(), this); | 2130 GetInterfaceRegistry(), this); |
| 2131 } | 2131 } |
| 2132 | 2132 |
| 2133 void RenderFrameHostImpl::ResetWaitingState() { | 2133 void RenderFrameHostImpl::ResetWaitingState() { |
| 2134 DCHECK(is_active()); | 2134 DCHECK(is_active()); |
| 2135 | 2135 |
| (...skipping 887 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3023 // handler after it's destroyed so it can't run after the RFHI is destroyed. | 3023 // handler after it's destroyed so it can't run after the RFHI is destroyed. |
| 3024 web_bluetooth_service_->SetClientConnectionErrorHandler(base::Bind( | 3024 web_bluetooth_service_->SetClientConnectionErrorHandler(base::Bind( |
| 3025 &RenderFrameHostImpl::DeleteWebBluetoothService, base::Unretained(this))); | 3025 &RenderFrameHostImpl::DeleteWebBluetoothService, base::Unretained(this))); |
| 3026 } | 3026 } |
| 3027 | 3027 |
| 3028 void RenderFrameHostImpl::DeleteWebBluetoothService() { | 3028 void RenderFrameHostImpl::DeleteWebBluetoothService() { |
| 3029 web_bluetooth_service_.reset(); | 3029 web_bluetooth_service_.reset(); |
| 3030 } | 3030 } |
| 3031 | 3031 |
| 3032 } // namespace content | 3032 } // namespace content |
| OLD | NEW |