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

Unified Diff: chrome/browser/chromeos/fileapi/file_system_backend.cc

Issue 341043008: Add FileSystemID parameter to IsolatedContext::RegisterFileSystemForPath. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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: chrome/browser/chromeos/fileapi/file_system_backend.cc
diff --git a/chrome/browser/chromeos/fileapi/file_system_backend.cc b/chrome/browser/chromeos/fileapi/file_system_backend.cc
index 04fd83f75dbbafa11cf5c2bfc608ab08f1567e6a..ff18a44800095da38d89eea5d4b2aac1dd2e2c69 100644
--- a/chrome/browser/chromeos/fileapi/file_system_backend.cc
+++ b/chrome/browser/chromeos/fileapi/file_system_backend.cc
@@ -96,12 +96,13 @@ void FileSystemBackend::ResolveURL(const fileapi::FileSystemURL& url,
const OpenFileSystemCallback& callback) {
std::string id;
fileapi::FileSystemType type;
+ std::string cracked_id;
base::FilePath path;
fileapi::FileSystemMountOption option;
if (!mount_points_->CrackVirtualPath(
- url.virtual_path(), &id, &type, &path, &option) &&
+ url.virtual_path(), &id, &type, &cracked_id, &path, &option) &&
!system_mount_points_->CrackVirtualPath(
- url.virtual_path(), &id, &type, &path, &option)) {
+ url.virtual_path(), &id, &type, &cracked_id, &path, &option)) {
// Not under a mount point, so return an error, since the root is not
// accessible.
GURL root_url = GURL(fileapi::GetExternalFileSystemRootURIString(
@@ -188,12 +189,13 @@ void FileSystemBackend::GrantFileAccessToExtension(
std::string id;
fileapi::FileSystemType type;
+ std::string cracked_id;
base::FilePath path;
fileapi::FileSystemMountOption option;
- if (!mount_points_->CrackVirtualPath(virtual_path,
- &id, &type, &path, &option) &&
- !system_mount_points_->CrackVirtualPath(virtual_path,
- &id, &type, &path, &option)) {
+ if (!mount_points_->CrackVirtualPath(virtual_path, &id, &type, &cracked_id,
+ &path, &option) &&
+ !system_mount_points_->CrackVirtualPath(virtual_path, &id, &type,
+ &cracked_id, &path, &option)) {
return;
}
@@ -278,7 +280,8 @@ fileapi::FileSystemOperation* FileSystemBackend::CreateFileSystemOperation(
bool FileSystemBackend::SupportsStreaming(
const fileapi::FileSystemURL& url) const {
return url.type() == fileapi::kFileSystemTypeDrive ||
- url.type() == fileapi::kFileSystemTypeProvided;
+ url.type() == fileapi::kFileSystemTypeProvided ||
+ url.type() == fileapi::kFileSystemTypeDeviceMediaAsFileStorage;
}
scoped_ptr<webkit_blob::FileStreamReader>
« no previous file with comments | « chrome/browser/chromeos/drive/file_system_util_unittest.cc ('k') | chrome/browser/devtools/devtools_file_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698