summaryrefslogtreecommitdiffstats
path: root/webkit/fileapi/file_system_operation.h
diff options
context:
space:
mode:
authorericu@google.com <ericu@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-16 00:02:53 +0000
committerericu@google.com <ericu@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-16 00:02:53 +0000
commit07c3d212963a1638659c4130f05bd5196957b2f6 (patch)
treef9fcfd54a7e26b443b1b941f80475725cb4d79cd /webkit/fileapi/file_system_operation.h
parent5800f19aa9967928eca31752678ac7d8e4e0cd1d (diff)
downloadchromium_src-07c3d212963a1638659c4130f05bd5196957b2f6.zip
chromium_src-07c3d212963a1638659c4130f05bd5196957b2f6.tar.gz
chromium_src-07c3d212963a1638659c4130f05bd5196957b2f6.tar.bz2
Let Pepper open FileSystem files again.
TEST=none [existing tests, but they're not currently run automatically] BUG=none Review URL: http://codereview.chromium.org/6850027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81837 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/fileapi/file_system_operation.h')
-rw-r--r--webkit/fileapi/file_system_operation.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/webkit/fileapi/file_system_operation.h b/webkit/fileapi/file_system_operation.h
index 8ca3be5..c726403 100644
--- a/webkit/fileapi/file_system_operation.h
+++ b/webkit/fileapi/file_system_operation.h
@@ -15,6 +15,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/message_loop_proxy.h"
#include "base/platform_file.h"
+#include "base/process.h"
#include "googleurl/src/gurl.h"
#include "webkit/fileapi/file_system_types.h"
#include "webkit/fileapi/file_system_operation_context.h"
@@ -79,6 +80,10 @@ class FileSystemOperation {
void TouchFile(const GURL& path,
const base::Time& last_access_time,
const base::Time& last_modified_time);
+ void OpenFile(
+ const GURL& path,
+ int file_flags,
+ base::ProcessHandle peer_handle);
// Try to cancel the current operation [we support cancelling write or
// truncate only]. Report failure for the current operation, then tell the
@@ -129,6 +134,10 @@ class FileSystemOperation {
int64 bytes,
bool complete);
void DidTouchFile(base::PlatformFileError rv);
+ void DidOpenFile(
+ base::PlatformFileError rv,
+ base::PassPlatformFile file,
+ bool created);
// Helper for Write().
void OnFileOpenedForWrite(
@@ -184,6 +193,7 @@ class FileSystemOperation {
kOperationWrite,
kOperationTruncate,
kOperationTouchFile,
+ kOperationOpenFile,
kOperationCancel,
};
@@ -206,6 +216,10 @@ class FileSystemOperation {
scoped_ptr<net::URLRequest> blob_request_;
scoped_ptr<FileSystemOperation> cancel_operation_;
+ // Used only by OpenFile, in order to clone the file handle back to the
+ // requesting process.
+ base::ProcessHandle peer_handle_;
+
DISALLOW_COPY_AND_ASSIGN(FileSystemOperation);
};