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

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

Issue 2379573006: bluetooth: Standardize Bluetooth adapter access in Adapter service. (Closed)
Patch Set: Change Mojo interface 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 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 #include "content/public/browser/web_contents.h" 163 #include "content/public/browser/web_contents.h"
164 #include "content/public/common/child_process_host.h" 164 #include "content/public/common/child_process_host.h"
165 #include "content/public/common/content_descriptors.h" 165 #include "content/public/common/content_descriptors.h"
166 #include "content/public/common/content_features.h" 166 #include "content/public/common/content_features.h"
167 #include "content/public/common/content_switches.h" 167 #include "content/public/common/content_switches.h"
168 #include "content/public/common/mojo_shell_connection.h" 168 #include "content/public/common/mojo_shell_connection.h"
169 #include "content/public/common/sandbox_type.h" 169 #include "content/public/common/sandbox_type.h"
170 #include "content/public/common/service_names.h" 170 #include "content/public/common/service_names.h"
171 #include "content/public/common/url_utils.h" 171 #include "content/public/common/url_utils.h"
172 #include "content/public/common/web_preferences.h" 172 #include "content/public/common/web_preferences.h"
173 #include "device/bluetooth/adapter.h" 173 #include "device/bluetooth/adapter_factory.h"
174 #include "device/bluetooth/public/interfaces/adapter.mojom.h" 174 #include "device/bluetooth/public/interfaces/adapter.mojom.h"
175 #include "device/usb/public/interfaces/chooser_service.mojom.h" 175 #include "device/usb/public/interfaces/chooser_service.mojom.h"
176 #include "device/usb/public/interfaces/device_manager.mojom.h" 176 #include "device/usb/public/interfaces/device_manager.mojom.h"
177 #include "gin/v8_initializer.h" 177 #include "gin/v8_initializer.h"
178 #include "net/base/mime_util.h" 178 #include "net/base/mime_util.h"
179 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" 179 #include "net/base/registry_controlled_domains/registry_controlled_domain.h"
180 #include "net/cookies/canonical_cookie.h" 180 #include "net/cookies/canonical_cookie.h"
181 #include "net/cookies/cookie_options.h" 181 #include "net/cookies/cookie_options.h"
182 #include "net/ssl/ssl_cert_request_info.h" 182 #include "net/ssl/ssl_cert_request_info.h"
183 #include "ppapi/host/ppapi_host.h" 183 #include "ppapi/host/ppapi_host.h"
(...skipping 2787 matching lines...) Expand 10 before | Expand all | Expand 10 after
2971 !render_frame_host->GetSiteInstance()->GetSiteURL().SchemeIs( 2971 !render_frame_host->GetSiteInstance()->GetSiteURL().SchemeIs(
2972 extensions::kExtensionScheme) 2972 extensions::kExtensionScheme)
2973 #endif 2973 #endif
2974 ) { 2974 ) {
2975 registry->AddInterface( 2975 registry->AddInterface(
2976 base::Bind(&CreateUsbDeviceManager, render_frame_host)); 2976 base::Bind(&CreateUsbDeviceManager, render_frame_host));
2977 registry->AddInterface( 2977 registry->AddInterface(
2978 base::Bind(&CreateWebUsbChooserService, render_frame_host)); 2978 base::Bind(&CreateWebUsbChooserService, render_frame_host));
2979 } 2979 }
2980 2980
2981 registry->AddInterface<bluetooth::mojom::Adapter>( 2981 registry->AddInterface<bluetooth::mojom::AdapterFactory>(
2982 base::Bind(&bluetooth::Adapter::Create)); 2982 base::Bind(&bluetooth::AdapterFactory::Create));
2983 2983
2984 if (!render_frame_host->GetParent()) { 2984 if (!render_frame_host->GetParent()) {
2985 // Register mojo CredentialManager interface only for main frame. 2985 // Register mojo CredentialManager interface only for main frame.
2986 registry->AddInterface( 2986 registry->AddInterface(
2987 base::Bind(&ChromePasswordManagerClient::BindCredentialManager, 2987 base::Bind(&ChromePasswordManagerClient::BindCredentialManager,
2988 render_frame_host)); 2988 render_frame_host));
2989 // Register mojo ContentTranslateDriver interface only for main frame. 2989 // Register mojo ContentTranslateDriver interface only for main frame.
2990 registry->AddInterface(base::Bind( 2990 registry->AddInterface(base::Bind(
2991 &ChromeTranslateClient::BindContentTranslateDriver, render_frame_host)); 2991 &ChromeTranslateClient::BindContentTranslateDriver, render_frame_host));
2992 } 2992 }
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
3277 if (channel <= kMaxDisableEncryptionChannel) { 3277 if (channel <= kMaxDisableEncryptionChannel) {
3278 static const char* const kWebRtcDevSwitchNames[] = { 3278 static const char* const kWebRtcDevSwitchNames[] = {
3279 switches::kDisableWebRtcEncryption, 3279 switches::kDisableWebRtcEncryption,
3280 }; 3280 };
3281 to_command_line->CopySwitchesFrom(from_command_line, 3281 to_command_line->CopySwitchesFrom(from_command_line,
3282 kWebRtcDevSwitchNames, 3282 kWebRtcDevSwitchNames,
3283 arraysize(kWebRtcDevSwitchNames)); 3283 arraysize(kWebRtcDevSwitchNames));
3284 } 3284 }
3285 } 3285 }
3286 #endif // defined(ENABLE_WEBRTC) 3286 #endif // defined(ENABLE_WEBRTC)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698