diff options
author | adamk@chromium.org <adamk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-19 23:39:56 +0000 |
---|---|---|
committer | adamk@chromium.org <adamk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-19 23:39:56 +0000 |
commit | 483cad04e9efc1b42f8b2b5b118a95a5650d3c3e (patch) | |
tree | 9b36f45f614a08e6c81798bb093101181dec195c /webkit/fileapi/file_system_operation.cc | |
parent | 048a1d02a9e9e42e63df1a26417d3f79494afb7c (diff) | |
download | chromium_src-483cad04e9efc1b42f8b2b5b118a95a5650d3c3e.zip chromium_src-483cad04e9efc1b42f8b2b5b118a95a5650d3c3e.tar.gz chromium_src-483cad04e9efc1b42f8b2b5b118a95a5650d3c3e.tar.bz2 |
Use appropriate FileSystemOperations in "filesystem:" URLRequestJobs.
FileSystemURLRequestJob now calls GetMetadata(), while FileSystemDirURLRequestJob
calls ReadDirectory(). With neither calling GetLocalPath(), the need for
FileSystemURLRequestJobBase has disappeared, as has the need for
FileSystemOperation::GetLocalPath and FileSystemCallbackDispatcher::DidGetLocalPath().
The only changes in behavior due to this patch are:
- ReadDirectory is now called on the URL, so it will still work properly
after the obsfuscated filesystem is in use.
- FileSystemDirURLRequestJob has been fixed to show a directory header.
This was somehow lost in the refactor to use FileSystemURLRequestJobBase.
- The error codes for "file not found" are now always net::ERR_FILE_NOT_FOUND.
R=ericu@chromium.org
Review URL: http://codereview.chromium.org/7047013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86015 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/fileapi/file_system_operation.cc')
-rw-r--r-- | webkit/fileapi/file_system_operation.cc | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/webkit/fileapi/file_system_operation.cc b/webkit/fileapi/file_system_operation.cc index 8479808..d3f1f37 100644 --- a/webkit/fileapi/file_system_operation.cc +++ b/webkit/fileapi/file_system_operation.cc @@ -321,32 +321,6 @@ void FileSystemOperation::FileExists(const GURL& path) { &FileSystemOperation::DidFileExists)); } -void FileSystemOperation::GetLocalPath(const GURL& path) { -#ifndef NDEBUG - DCHECK(kOperationNone == pending_operation_); - pending_operation_ = kOperationGetLocalPath; -#endif - - FilePath virtual_path; - GURL origin_url; - FileSystemType type; - FileSystemFileUtil* file_system_file_util; - if (!VerifyFileSystemPathForRead(path, &origin_url, &type, &virtual_path, - &file_system_file_util)) { - delete this; - return; - } - file_system_operation_context_.set_src_origin_url(origin_url); - file_system_operation_context_.set_src_type(type); - if (!file_system_operation_context_.src_file_system_file_util()) - file_system_operation_context_.set_src_file_system_file_util( - file_system_file_util); - FileSystemFileUtilProxy::GetLocalPath( - file_system_operation_context_, - proxy_, virtual_path, callback_factory_.NewCallback( - &FileSystemOperation::DidGetLocalPath)); -} - void FileSystemOperation::GetMetadata(const GURL& path) { #ifndef NDEBUG DCHECK(kOperationNone == pending_operation_); @@ -738,16 +712,6 @@ void FileSystemOperation::DidFileExists( delete this; } -void FileSystemOperation::DidGetLocalPath( - base::PlatformFileError rv, - const FilePath& local_path) { - if (rv == base::PLATFORM_FILE_OK) - dispatcher_->DidGetLocalPath(local_path); - else - dispatcher_->DidFail(rv); - delete this; -} - void FileSystemOperation::DidGetMetadata( base::PlatformFileError rv, const base::PlatformFileInfo& file_info, |