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

Unified Diff: services/preferences/public/interfaces/preferences.mojom

Issue 2777483002: Pref service: Add initial support for pref registration. (Closed)
Patch Set: rebase 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
« no previous file with comments | « services/preferences/public/cpp/pref_service_factory.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/preferences/public/interfaces/preferences.mojom
diff --git a/services/preferences/public/interfaces/preferences.mojom b/services/preferences/public/interfaces/preferences.mojom
index 0225a8486d4c7a41afd01051589ddf08ac736532..eab0b6074b453d459e102b1a8a5155d9b00a85fc 100644
--- a/services/preferences/public/interfaces/preferences.mojom
+++ b/services/preferences/public/interfaces/preferences.mojom
@@ -112,8 +112,9 @@ interface PrefStoreConnector {
// prefs in each store and an |observer| interfaces through which updates can
// be received.
[Sync]
- Connect() => (PersistentPrefStoreConnection connection,
- map<PrefStoreType, PrefStoreConnection> connections);
+ Connect(PrefRegistry pref_registry) =>
+ (PersistentPrefStoreConnection connection,
+ map<PrefStoreType, PrefStoreConnection> connections);
};
// An interface providing mutation access to a PersistentPrefStore.
@@ -128,6 +129,20 @@ interface PersistentPrefStore {
ClearMutableValues();
};
+// A registry of all prefs registered by a single client.
+struct PrefRegistry {
+ map<string, PrefRegistration> registrations;
+};
+
+struct PrefRegistration {
+ mojo.common.mojom.Value default_value;
+
+ // A bitfield of flags. Flag values are defined in
+ // PrefRegistry::PrefRegistrationFlags and
+ // PrefRegistrySyncable::PrefRegistrationFlags.
+ uint32 flags;
+};
+
interface PrefServiceControl {
// Initializes the pref service. This must be called before the service can
// be used.
« no previous file with comments | « services/preferences/public/cpp/pref_service_factory.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698