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

Unified Diff: content/browser/service_manager/service_manager_context.cc

Issue 2871353002: GRC: Added Tab coordination units behind a feature flag (Closed)
Patch Set: Rebase Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/public/app/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/service_manager/service_manager_context.cc
diff --git a/content/browser/service_manager/service_manager_context.cc b/content/browser/service_manager/service_manager_context.cc
index f46295e1affa8c741bb32c73b18e234146068b64..f13e9e69f67cfaf16d130932b5605d81aca68595 100644
--- a/content/browser/service_manager/service_manager_context.cc
+++ b/content/browser/service_manager/service_manager_context.cc
@@ -41,6 +41,9 @@
#include "services/data_decoder/public/interfaces/constants.mojom.h"
#include "services/device/device_service.h"
#include "services/device/public/interfaces/constants.mojom.h"
+#include "services/resource_coordinator/public/cpp/resource_coordinator_features.h"
+#include "services/resource_coordinator/public/interfaces/service_constants.mojom.h"
+#include "services/resource_coordinator/resource_coordinator_service.h"
#include "services/service_manager/connect_params.h"
#include "services/service_manager/public/cpp/connector.h"
#include "services/service_manager/public/cpp/service.h"
@@ -314,6 +317,14 @@ ServiceManagerContext::ServiceManagerContext() {
packaged_services_connection_->AddEmbeddedService(device::mojom::kServiceName,
device_info);
+ if (base::FeatureList::IsEnabled(features::kGlobalResourceCoordinator)) {
+ ServiceInfo resource_coordinator_info;
+ resource_coordinator_info.factory =
+ base::Bind(&resource_coordinator::ResourceCoordinatorService::Create);
+ packaged_services_connection_->AddEmbeddedService(
+ resource_coordinator::mojom::kServiceName, resource_coordinator_info);
+ }
+
ContentBrowserClient::StaticServiceMap services;
GetContentClient()->browser()->RegisterInProcessServices(&services);
for (const auto& entry : services) {
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/public/app/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698