diff options
author | hirono <hirono@chromium.org> | 2014-09-05 03:25:34 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-05 10:28:49 +0000 |
commit | d9cf42f666d09f57c4592f945fe5085b88eb38de (patch) | |
tree | 30266088364d3fc8fbcdad14d6a8cb0d4d9866d0 /webkit | |
parent | f62dbf9674ab7ad07e58daf40b1e49e3a7ed7b22 (diff) | |
download | chromium_src-d9cf42f666d09f57c4592f945fe5085b88eb38de.zip chromium_src-d9cf42f666d09f57c4592f945fe5085b88eb38de.tar.gz chromium_src-d9cf42f666d09f57c4592f945fe5085b88eb38de.tar.bz2 |
Add GetURLForBrowserTab method to the external file system backend.
The method will be called from FileSystemURLRequestJob class to redirect requests for the drive hosted documents.
BUG=367027
TEST=manually; Add the method call to FileSystemURLRequestJob and open FileSystemURL in browser tab.
Review URL: https://codereview.chromium.org/527773003
Cr-Commit-Position: refs/heads/master@{#293494}
Diffstat (limited to 'webkit')
-rw-r--r-- | webkit/browser/fileapi/file_system_backend.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/webkit/browser/fileapi/file_system_backend.h b/webkit/browser/fileapi/file_system_backend.h index b71c8ca..43bc3af 100644 --- a/webkit/browser/fileapi/file_system_backend.h +++ b/webkit/browser/fileapi/file_system_backend.h @@ -20,14 +20,11 @@ class GURL; namespace storage { -class FileStreamReader; -} - -namespace storage { class AsyncFileUtil; class CopyOrMoveFileValidatorFactory; class FileSystemURL; +class FileStreamReader; class FileStreamWriter; class FileSystemContext; class FileSystemFileUtil; @@ -35,6 +32,9 @@ class FileSystemOperation; class FileSystemQuotaUtil; class WatcherManager; +// Callback to take GURL. +typedef base::Callback<void(const GURL& url)> URLCallback; + // An interface for defining a file system backend. // // NOTE: when you implement a new FileSystemBackend for your own @@ -157,6 +157,11 @@ class ExternalFileSystemBackend : public FileSystemBackend { // path is not exposed by this provider. virtual bool GetVirtualPath(const base::FilePath& file_system_path, base::FilePath* virtual_path) = 0; + // Gets a redirect URL for contents. e.g. Google Drive URL for hosted + // documents. Returns empty URL if the entry does not have the redirect URL. + virtual void GetRedirectURLForContents( + const storage::FileSystemURL& url, + const storage::URLCallback& callback) = 0; }; } // namespace storage |