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

Unified Diff: services/preferences/public/cpp/pref_service_factory.cc

Issue 2772673002: mash: switch to the new pref service (Closed)
Patch Set: Address review comments Created 3 years, 9 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
Index: services/preferences/public/cpp/pref_service_factory.cc
diff --git a/services/preferences/public/cpp/pref_service_factory.cc b/services/preferences/public/cpp/pref_service_factory.cc
index 1fae6bc8f59f848b88c6c03c3a3188da8748cf4e..d1a48c3d3794740eebcc6221a1f768feb5f6604d 100644
--- a/services/preferences/public/cpp/pref_service_factory.cc
+++ b/services/preferences/public/cpp/pref_service_factory.cc
@@ -97,10 +97,11 @@ void OnConnectError(
void ConnectToPrefService(service_manager::Connector* connector,
scoped_refptr<PrefRegistry> pref_registry,
- ConnectCallback callback) {
+ ConnectCallback callback,
+ base::StringPiece service_name) {
auto connector_ptr = make_scoped_refptr(
new RefCountedInterfacePtr<mojom::PrefStoreConnector>());
- connector->BindInterface(mojom::kPrefStoreServiceName, &connector_ptr->get());
+ connector->BindInterface(service_name.as_string(), &connector_ptr->get());
connector_ptr->get().set_connection_error_handler(base::Bind(
&OnConnectError, connector_ptr, base::Passed(ConnectCallback{callback})));
auto serialized_pref_registry = SerializePrefRegistry(*pref_registry);
« no previous file with comments | « services/preferences/public/cpp/pref_service_factory.h ('k') | services/preferences/public/interfaces/preferences.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698