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

Side by Side Diff: base/prefs/writeable_pref_store.h

Issue 389333003: Leftover cleanups from https://codereview.chromium.org/324493002 . (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « base/prefs/value_map_pref_store.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef BASE_PREFS_WRITEABLE_PREF_STORE_H_ 5 #ifndef BASE_PREFS_WRITEABLE_PREF_STORE_H_
6 #define BASE_PREFS_WRITEABLE_PREF_STORE_H_ 6 #define BASE_PREFS_WRITEABLE_PREF_STORE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 18 matching lines...) Expand all
29 // Equivalent to PrefStore::GetValue but returns a mutable value. 29 // Equivalent to PrefStore::GetValue but returns a mutable value.
30 virtual bool GetMutableValue(const std::string& key, 30 virtual bool GetMutableValue(const std::string& key,
31 base::Value** result) = 0; 31 base::Value** result) = 0;
32 32
33 // Triggers a value changed notification. This function needs to be called 33 // Triggers a value changed notification. This function needs to be called
34 // if one retrieves a list or dictionary with GetMutableValue and change its 34 // if one retrieves a list or dictionary with GetMutableValue and change its
35 // value. SetValue takes care of notifications itself. Note that 35 // value. SetValue takes care of notifications itself. Note that
36 // ReportValueChanged will trigger notifications even if nothing has changed. 36 // ReportValueChanged will trigger notifications even if nothing has changed.
37 virtual void ReportValueChanged(const std::string& key) = 0; 37 virtual void ReportValueChanged(const std::string& key) = 0;
38 38
39 // Same as SetValue, but doesn't generate notifications. This is used by
40 // PrefService::GetMutableUserPref() in order to put empty entries
41 // into the user pref store. Using SetValue is not an option since existing
42 // tests rely on the number of notifications generated.
43 virtual void SetValueSilently(const std::string& key, base::Value* value) = 0;
39 44
40 protected: 45 protected:
41 virtual ~WriteablePrefStore() {} 46 virtual ~WriteablePrefStore() {}
42 47
43 private: 48 private:
44 DISALLOW_COPY_AND_ASSIGN(WriteablePrefStore); 49 DISALLOW_COPY_AND_ASSIGN(WriteablePrefStore);
45 }; 50 };
46 51
47 #endif // BASE_PREFS_WRITEABLE_PREF_STORE_H_ 52 #endif // BASE_PREFS_WRITEABLE_PREF_STORE_H_
OLDNEW
« no previous file with comments | « base/prefs/value_map_pref_store.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698