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

Unified Diff: components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h

Issue 1643733002: Revert of mojo filesystem: Simplify full file reading/writing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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: components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h
diff --git a/components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h b/components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h
index 75cdead7ad910385570cdd5655cce2cc5f7d6076..685b361f491002e6ab4fb785bd374211866de257 100644
--- a/components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h
+++ b/components/filesystem/public/cpp/prefs/filesystem_json_pref_store.h
@@ -140,11 +140,14 @@
// Asynchronous implementation details of PerformWrite().
void OnTempFileWriteStart();
- void OnTempFileWrite(FileError err);
+ void OnTempFileOpened(FileError err);
+ void OnTempFileWrite(FileError err, uint32_t num_bytes_written);
+ void OnTempFileClosed(FileError err);
void OnTempFileRenamed(FileError err);
// Asynchronous implementation details of ReadPrefsAsync().
void OnPreferencesReadStart();
+ void OnPreferencesFileOpened(FileError err);
void OnPreferencesFileRead(FileError err, mojo::Array<uint8_t> contents);
const std::string path_;
@@ -154,6 +157,9 @@
// |directory_| is only bound after the first attempt to access the
// |filesystem. See OpenFilesystem().
DirectoryPtr directory_;
+
+ FilePtr preferences_file_;
+ FilePtr temporary_file_;
scoped_ptr<base::DictionaryValue> prefs_;
« no previous file with comments | « components/filesystem/file_impl.cc ('k') | components/filesystem/public/cpp/prefs/filesystem_json_pref_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698