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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2379573006: bluetooth: Standardize Bluetooth adapter access in Adapter service. (Closed)
Patch Set: Comment updates Created 4 years, 2 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
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 "chrome/browser/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 #include "content/public/browser/web_contents.h" 162 #include "content/public/browser/web_contents.h"
163 #include "content/public/common/child_process_host.h" 163 #include "content/public/common/child_process_host.h"
164 #include "content/public/common/content_descriptors.h" 164 #include "content/public/common/content_descriptors.h"
165 #include "content/public/common/content_features.h" 165 #include "content/public/common/content_features.h"
166 #include "content/public/common/content_switches.h" 166 #include "content/public/common/content_switches.h"
167 #include "content/public/common/mojo_shell_connection.h" 167 #include "content/public/common/mojo_shell_connection.h"
168 #include "content/public/common/sandbox_type.h" 168 #include "content/public/common/sandbox_type.h"
169 #include "content/public/common/service_names.h" 169 #include "content/public/common/service_names.h"
170 #include "content/public/common/url_utils.h" 170 #include "content/public/common/url_utils.h"
171 #include "content/public/common/web_preferences.h" 171 #include "content/public/common/web_preferences.h"
172 #include "device/bluetooth/adapter.h" 172 #include "device/bluetooth/adapter_factory.h"
173 #include "device/bluetooth/public/interfaces/adapter.mojom.h" 173 #include "device/bluetooth/public/interfaces/adapter.mojom.h"
174 #include "device/usb/public/interfaces/chooser_service.mojom.h" 174 #include "device/usb/public/interfaces/chooser_service.mojom.h"
175 #include "device/usb/public/interfaces/device_manager.mojom.h" 175 #include "device/usb/public/interfaces/device_manager.mojom.h"
176 #include "gin/v8_initializer.h" 176 #include "gin/v8_initializer.h"
177 #include "net/base/mime_util.h" 177 #include "net/base/mime_util.h"
178 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" 178 #include "net/base/registry_controlled_domains/registry_controlled_domain.h"
179 #include "net/cookies/canonical_cookie.h" 179 #include "net/cookies/canonical_cookie.h"
180 #include "net/cookies/cookie_options.h" 180 #include "net/cookies/cookie_options.h"
181 #include "net/ssl/ssl_cert_request_info.h" 181 #include "net/ssl/ssl_cert_request_info.h"
182 #include "ppapi/host/ppapi_host.h" 182 #include "ppapi/host/ppapi_host.h"
(...skipping 2775 matching lines...) Expand 10 before | Expand all | Expand 10 after
2958 !render_frame_host->GetSiteInstance()->GetSiteURL().SchemeIs( 2958 !render_frame_host->GetSiteInstance()->GetSiteURL().SchemeIs(
2959 extensions::kExtensionScheme) 2959 extensions::kExtensionScheme)
2960 #endif 2960 #endif
2961 ) { 2961 ) {
2962 registry->AddInterface( 2962 registry->AddInterface(
2963 base::Bind(&CreateUsbDeviceManager, render_frame_host)); 2963 base::Bind(&CreateUsbDeviceManager, render_frame_host));
2964 registry->AddInterface( 2964 registry->AddInterface(
2965 base::Bind(&CreateWebUsbChooserService, render_frame_host)); 2965 base::Bind(&CreateWebUsbChooserService, render_frame_host));
2966 } 2966 }
2967 2967
2968 registry->AddInterface<bluetooth::mojom::Adapter>( 2968 registry->AddInterface<bluetooth::mojom::AdapterFactory>(
2969 base::Bind(&bluetooth::Adapter::Create)); 2969 base::Bind(&bluetooth::AdapterFactory::Create));
2970 2970
2971 if (!render_frame_host->GetParent()) { 2971 if (!render_frame_host->GetParent()) {
2972 // Register mojo CredentialManager interface only for main frame. 2972 // Register mojo CredentialManager interface only for main frame.
2973 registry->AddInterface( 2973 registry->AddInterface(
2974 base::Bind(&ChromePasswordManagerClient::BindCredentialManager, 2974 base::Bind(&ChromePasswordManagerClient::BindCredentialManager,
2975 render_frame_host)); 2975 render_frame_host));
2976 // Register mojo ContentTranslateDriver interface only for main frame. 2976 // Register mojo ContentTranslateDriver interface only for main frame.
2977 registry->AddInterface(base::Bind( 2977 registry->AddInterface(base::Bind(
2978 &ChromeTranslateClient::BindContentTranslateDriver, render_frame_host)); 2978 &ChromeTranslateClient::BindContentTranslateDriver, render_frame_host));
2979 } 2979 }
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
3262 if (channel <= kMaxDisableEncryptionChannel) { 3262 if (channel <= kMaxDisableEncryptionChannel) {
3263 static const char* const kWebRtcDevSwitchNames[] = { 3263 static const char* const kWebRtcDevSwitchNames[] = {
3264 switches::kDisableWebRtcEncryption, 3264 switches::kDisableWebRtcEncryption,
3265 }; 3265 };
3266 to_command_line->CopySwitchesFrom(from_command_line, 3266 to_command_line->CopySwitchesFrom(from_command_line,
3267 kWebRtcDevSwitchNames, 3267 kWebRtcDevSwitchNames,
3268 arraysize(kWebRtcDevSwitchNames)); 3268 arraysize(kWebRtcDevSwitchNames));
3269 } 3269 }
3270 } 3270 }
3271 #endif // defined(ENABLE_WEBRTC) 3271 #endif // defined(ENABLE_WEBRTC)
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/bluetooth_internals/bluetooth_internals.js » ('j') | device/bluetooth/adapter.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698