summaryrefslogtreecommitdiffstats
path: root/chrome/common/file_system
diff options
context:
space:
mode:
authordumi@chromium.org <dumi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-27 21:22:01 +0000
committerdumi@chromium.org <dumi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-27 21:22:01 +0000
commited7ae173fbca0de5cb95c990fed727ea15172cd4 (patch)
treee94ae0632eec0d649dad8fa1953cf0932c35cbda /chrome/common/file_system
parent6783d72a34e5d25655d5c9d054f2700f3d2488ff (diff)
downloadchromium_src-ed7ae173fbca0de5cb95c990fed727ea15172cd4.zip
chromium_src-ed7ae173fbca0de5cb95c990fed727ea15172cd4.tar.gz
chromium_src-ed7ae173fbca0de5cb95c990fed727ea15172cd4.tar.bz2
Adding a TouchFile() operation.
BUG=none TEST=none Review URL: http://codereview.chromium.org/3417018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60710 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/file_system')
-rw-r--r--chrome/common/file_system/file_system_dispatcher.cc11
-rw-r--r--chrome/common/file_system/file_system_dispatcher.h4
2 files changed, 15 insertions, 0 deletions
diff --git a/chrome/common/file_system/file_system_dispatcher.cc b/chrome/common/file_system/file_system_dispatcher.cc
index 6f5d2a3..0e46c97 100644
--- a/chrome/common/file_system/file_system_dispatcher.cc
+++ b/chrome/common/file_system/file_system_dispatcher.cc
@@ -108,6 +108,17 @@ bool FileSystemDispatcher::ReadDirectory(
new ViewHostMsg_FileSystem_ReadDirectory(request_id, path));
}
+bool FileSystemDispatcher::TouchFile(
+ const FilePath& path,
+ const base::Time& last_access_time,
+ const base::Time& last_modified_time,
+ fileapi::FileSystemCallbackDispatcher* dispatcher) {
+ int request_id = dispatchers_.Add(dispatcher);
+ return ChildThread::current()->Send(
+ new ViewHostMsg_FileSystem_TouchFile(
+ request_id, path, last_access_time, last_modified_time));
+}
+
void FileSystemDispatcher::OnOpenFileSystemRequestComplete(
int request_id, bool accepted, const std::string& name,
const FilePath& root_path) {
diff --git a/chrome/common/file_system/file_system_dispatcher.h b/chrome/common/file_system/file_system_dispatcher.h
index 58b3cc72..ec20e6d 100644
--- a/chrome/common/file_system/file_system_dispatcher.h
+++ b/chrome/common/file_system/file_system_dispatcher.h
@@ -56,6 +56,10 @@ class FileSystemDispatcher {
fileapi::FileSystemCallbackDispatcher* dispatcher);
bool ReadDirectory(const FilePath& path,
fileapi::FileSystemCallbackDispatcher* dispatcher);
+ bool TouchFile(const FilePath& file_path,
+ const base::Time& last_access_time,
+ const base::Time& last_modified_time,
+ fileapi::FileSystemCallbackDispatcher* dispatcher);
private:
// Message handler for OpenFileSystem.