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

Unified Diff: webkit/fileapi/syncable/canned_syncable_file_system.cc

Issue 11363161: Add CannedSyncableFileSystem::TouchFile for testing (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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: webkit/fileapi/syncable/canned_syncable_file_system.cc
diff --git a/webkit/fileapi/syncable/canned_syncable_file_system.cc b/webkit/fileapi/syncable/canned_syncable_file_system.cc
index 6ba8c074ab887b7fd01d55d5db0e32d6a634de3e..7b487b7b5fa03e1bf39edb65dab1a7ece4b34480 100644
--- a/webkit/fileapi/syncable/canned_syncable_file_system.cc
+++ b/webkit/fileapi/syncable/canned_syncable_file_system.cc
@@ -292,6 +292,17 @@ PlatformFileError CannedSyncableFileSystem::TruncateFile(
base::Unretained(this), url, size));
}
+PlatformFileError CannedSyncableFileSystem::TouchFile(
+ const FileSystemURL& url,
+ const base::Time& access_time,
+ const base::Time& modified_time) {
+ return RunOnThread<PlatformFileError>(
+ io_task_runner_,
+ FROM_HERE,
+ base::Bind(&CannedSyncableFileSystem::DoTouchFile,
+ base::Unretained(this), url, access_time, modified_time));
+}
+
PlatformFileError CannedSyncableFileSystem::Remove(
const FileSystemURL& url, bool recursive) {
return RunOnThread<PlatformFileError>(
@@ -438,6 +449,14 @@ void CannedSyncableFileSystem::DoTruncateFile(
NewOperation()->Truncate(url, size, callback);
}
+void CannedSyncableFileSystem::DoTouchFile(
+ const FileSystemURL& url,
+ const base::Time& access_time, const base::Time& modified_time,
nhiroki 2012/11/09 07:50:03 nit: please add line break after "access_time,".
kinuko 2012/11/09 07:55:33 Done... (by the way just to clarify, I don't thin
+ const StatusCallback& callback) {
+ EXPECT_TRUE(is_filesystem_opened_);
+ NewOperation()->TouchFile(url, access_time, modified_time, callback);
+}
+
void CannedSyncableFileSystem::DoRemove(
const FileSystemURL& url, bool recursive,
const StatusCallback& callback) {

Powered by Google App Engine
This is Rietveld 408576698