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

Unified Diff: webkit/fileapi/file_system_context.cc

Issue 10082002: Add FileSystemMountPointProvider::CreateFileReader() which returns appropriate Reader instance (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 8 years, 8 months 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/file_system_context.cc
diff --git a/webkit/fileapi/file_system_context.cc b/webkit/fileapi/file_system_context.cc
index a700221dfcb10dc7b1f1f8f43683e02904c7b2a8..e64f4979edbc420f1892881799b0d9e1d748ec00 100644
--- a/webkit/fileapi/file_system_context.cc
+++ b/webkit/fileapi/file_system_context.cc
@@ -190,4 +190,20 @@ FileSystemOperationInterface* FileSystemContext::CreateFileSystemOperation(
origin_url, file_system_type, file_path, file_proxy, this);
}
+webkit_blob::FileReader* FileSystemContext::CreateFileReader(
+ const GURL& url,
+ int64 offset,
+ base::MessageLoopProxy* file_proxy) {
+ GURL origin_url;
+ FileSystemType file_system_type = kFileSystemTypeUnknown;
+ FilePath file_path;
+ if (!CrackFileSystemURL(url, &origin_url, &file_system_type, &file_path))
+ return NULL;
+ FileSystemMountPointProvider* mount_point_provider =
+ GetMountPointProvider(file_system_type);
+ if (!mount_point_provider)
+ return NULL;
+ return mount_point_provider->CreateFileReader(url, offset, file_proxy, this);
+}
+
} // namespace fileapi

Powered by Google App Engine
This is Rietveld 408576698