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

Side by Side Diff: content/browser/service_manager/service_manager_context.cc

Issue 2653963002: [Experimental] Supporting OOPIF printing
Patch Set: Rename service, fix for webview, and connect to DiscardableMemoryManager Created 3 years, 8 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/service_manager/service_manager_context.h" 5 #include "content/browser/service_manager/service_manager_context.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 void StartUtilityProcessOnIOThread( 53 void StartUtilityProcessOnIOThread(
54 service_manager::mojom::ServiceFactoryRequest request, 54 service_manager::mojom::ServiceFactoryRequest request,
55 const base::string16& process_name, 55 const base::string16& process_name,
56 bool use_sandbox) { 56 bool use_sandbox) {
57 UtilityProcessHost* process_host = 57 UtilityProcessHost* process_host =
58 UtilityProcessHost::Create(nullptr, nullptr); 58 UtilityProcessHost::Create(nullptr, nullptr);
59 process_host->SetName(process_name); 59 process_host->SetName(process_name);
60 if (!use_sandbox) 60 if (!use_sandbox)
61 process_host->DisableSandbox(); 61 process_host->DisableSandbox();
62 process_host->Start(); 62 process_host->Start();
63 process_host->RegisterMojoServices();
63 process_host->GetRemoteInterfaces()->GetInterface(std::move(request)); 64 process_host->GetRemoteInterfaces()->GetInterface(std::move(request));
64 } 65 }
65 66
66 void StartServiceInUtilityProcess( 67 void StartServiceInUtilityProcess(
67 const std::string& service_name, 68 const std::string& service_name,
68 const base::string16& process_name, 69 const base::string16& process_name,
69 bool use_sandbox, 70 bool use_sandbox,
70 service_manager::mojom::ServiceRequest request) { 71 service_manager::mojom::ServiceRequest request) {
71 service_manager::mojom::ServiceFactoryPtr service_factory; 72 service_manager::mojom::ServiceFactoryPtr service_factory;
72 BrowserThread::PostTask( 73 BrowserThread::PostTask(
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 base::Bind(&DestroyConnectorOnIOThread)); 352 base::Bind(&DestroyConnectorOnIOThread));
352 } 353 }
353 354
354 // static 355 // static
355 service_manager::Connector* ServiceManagerContext::GetConnectorForIOThread() { 356 service_manager::Connector* ServiceManagerContext::GetConnectorForIOThread() {
356 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 357 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
357 return g_io_thread_connector.Get().get(); 358 return g_io_thread_connector.Get().get();
358 } 359 }
359 360
360 } // namespace content 361 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_proxy_host.cc ('k') | content/browser/utility_process_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698