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

Unified Diff: chrome/browser/prefs/pref_service.cc

Issue 6713032: Provide lazy CommitPendingWrites in addition to eager SavePersistentPrefs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: removed notification + rebase Created 9 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: chrome/browser/prefs/pref_service.cc
diff --git a/chrome/browser/prefs/pref_service.cc b/chrome/browser/prefs/pref_service.cc
index 373a86f55381230ba1761978065a277cb6b56416..d9588b56a1b83f14d71fc1f33ddd08f0b6844789 100644
--- a/chrome/browser/prefs/pref_service.cc
+++ b/chrome/browser/prefs/pref_service.cc
@@ -213,16 +213,19 @@ bool PrefService::ReloadPersistentPrefs() {
bool PrefService::SavePersistentPrefs() {
DCHECK(CalledOnValidThread());
-
return user_pref_store_->WritePrefs();
}
void PrefService::ScheduleSavePersistentPrefs() {
DCHECK(CalledOnValidThread());
-
user_pref_store_->ScheduleWritePrefs();
}
+void PrefService::CommitPendingWrite() {
+ DCHECK(CalledOnValidThread());
+ user_pref_store_->CommitPendingWrite();
+}
+
void PrefService::RegisterBooleanPref(const char* path,
bool default_value) {
RegisterPreference(path, Value::CreateBooleanValue(default_value));

Powered by Google App Engine
This is Rietveld 408576698