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

Side by Side Diff: chrome/utility/chrome_content_utility_client.cc

Issue 2610953003: Convert utility process WiFi Credentials IPC to mojo (Closed)
Patch Set: Add mojom test network name. Created 3 years, 11 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
« no previous file with comments | « chrome/test/BUILD.gn ('k') | chrome/utility/chrome_content_utility_ipc_whitelist.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/utility/chrome_content_utility_client.h" 5 #include "chrome/utility/chrome_content_utility_client.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 void ChromeContentUtilityClient::ExposeInterfacesToBrowser( 193 void ChromeContentUtilityClient::ExposeInterfacesToBrowser(
194 service_manager::InterfaceRegistry* registry) { 194 service_manager::InterfaceRegistry* registry) {
195 const bool running_elevated = 195 const bool running_elevated =
196 base::CommandLine::ForCurrentProcess()->HasSwitch( 196 base::CommandLine::ForCurrentProcess()->HasSwitch(
197 switches::kUtilityProcessRunningElevated); 197 switches::kUtilityProcessRunningElevated);
198 #if BUILDFLAG(ENABLE_EXTENSIONS) 198 #if BUILDFLAG(ENABLE_EXTENSIONS)
199 ChromeContentUtilityClient* utility_client = this; 199 ChromeContentUtilityClient* utility_client = this;
200 extensions::ExtensionsHandler::ExposeInterfacesToBrowser( 200 extensions::ExtensionsHandler::ExposeInterfacesToBrowser(
201 registry, utility_client, running_elevated); 201 registry, utility_client, running_elevated);
202 #endif 202 #endif
203 // If our process runs with elevated privileges, only add elevated 203 // If our process runs with elevated privileges, only add elevated Mojo
204 // Mojo services to the interface registry. 204 // services to the interface registry.
205 if (running_elevated) 205 if (running_elevated)
206 return; 206 return;
207 207
208 #if !defined(OS_ANDROID) 208 #if !defined(OS_ANDROID)
209 registry->AddInterface<net::interfaces::ProxyResolverFactory>( 209 registry->AddInterface<net::interfaces::ProxyResolverFactory>(
210 base::Bind(CreateProxyResolverFactory)); 210 base::Bind(CreateProxyResolverFactory));
211 registry->AddInterface(base::Bind(CreateResourceUsageReporter)); 211 registry->AddInterface(base::Bind(CreateResourceUsageReporter));
212 registry->AddInterface(base::Bind(&ProfileImportHandler::Create)); 212 registry->AddInterface(base::Bind(&ProfileImportHandler::Create));
213 #endif 213 #endif
214 registry->AddInterface( 214 registry->AddInterface(
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 safe_browsing::zip_analyzer::Results results; 312 safe_browsing::zip_analyzer::Results results;
313 safe_browsing::dmg::AnalyzeDMGFile( 313 safe_browsing::dmg::AnalyzeDMGFile(
314 IPC::PlatformFileForTransitToFile(dmg_file), &results); 314 IPC::PlatformFileForTransitToFile(dmg_file), &results);
315 Send(new ChromeUtilityHostMsg_AnalyzeDmgFileForDownloadProtection_Finished( 315 Send(new ChromeUtilityHostMsg_AnalyzeDmgFileForDownloadProtection_Finished(
316 results)); 316 results));
317 ReleaseProcessIfNeeded(); 317 ReleaseProcessIfNeeded();
318 } 318 }
319 #endif // defined(OS_MACOSX) 319 #endif // defined(OS_MACOSX)
320 320
321 #endif // defined(FULL_SAFE_BROWSING) 321 #endif // defined(FULL_SAFE_BROWSING)
OLDNEW
« no previous file with comments | « chrome/test/BUILD.gn ('k') | chrome/utility/chrome_content_utility_ipc_whitelist.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698