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

Unified Diff: base/prefs/pref_store.h

Issue 11365112: Change PrefStore::ReadResult to a boolean. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 8 years, 1 month 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: base/prefs/pref_store.h
diff --git a/base/prefs/pref_store.h b/base/prefs/pref_store.h
index 264c1d4f1dc60699504ca20ce8fccb0f8ebf1429..22395288d1b99d8c11c539045ed1d489c344f33f 100644
--- a/base/prefs/pref_store.h
+++ b/base/prefs/pref_store.h
@@ -36,16 +36,6 @@ class BASE_PREFS_EXPORT PrefStore : public base::RefCounted<PrefStore> {
virtual ~Observer() {}
};
- // Return values for GetValue().
- enum ReadResult {
- // Value found and returned.
- READ_OK,
- // No value present, but skip other pref stores and use default.
- READ_USE_DEFAULT,
- // No value present.
- READ_NO_VALUE,
- };
-
PrefStore() {}
// Add and remove observers.
@@ -57,10 +47,10 @@ class BASE_PREFS_EXPORT PrefStore : public base::RefCounted<PrefStore> {
virtual bool IsInitializationComplete() const;
// Get the value for a given preference |key| and stores it in |*result|.
- // |*result| is only modified if the return value is READ_OK and if |result|
+ // |*result| is only modified if the return value is true and if |result|
// is not NULL. Ownership of the |*result| value remains with the PrefStore.
- virtual ReadResult GetValue(const std::string& key,
- const base::Value** result) const = 0;
+ virtual bool GetValue(const std::string& key,
+ const base::Value** result) const = 0;
protected:
friend class base::RefCounted<PrefStore>;

Powered by Google App Engine
This is Rietveld 408576698