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

Unified Diff: chrome/browser/extensions/api/developer_private/developer_private_api.cc

Issue 442383002: Move storage-related files from webkit/ to new top-level directory storage/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 4 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/extensions/api/developer_private/developer_private_api.cc
diff --git a/chrome/browser/extensions/api/developer_private/developer_private_api.cc b/chrome/browser/extensions/api/developer_private/developer_private_api.cc
index 615789a26cd2be18020aa85d326fb5bb6e604a27..563d82cd7733c972cf481deeebaba00a53dbd27f 100644
--- a/chrome/browser/extensions/api/developer_private/developer_private_api.cc
+++ b/chrome/browser/extensions/api/developer_private/developer_private_api.cc
@@ -73,12 +73,12 @@
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/resource/resource_bundle.h"
#include "ui/base/webui/web_ui_util.h"
-#include "webkit/browser/fileapi/external_mount_points.h"
-#include "webkit/browser/fileapi/file_system_context.h"
-#include "webkit/browser/fileapi/file_system_operation.h"
-#include "webkit/browser/fileapi/file_system_operation_runner.h"
-#include "webkit/browser/fileapi/isolated_context.h"
-#include "webkit/common/blob/shareable_file_reference.h"
+#include "storage/browser/fileapi/external_mount_points.h"
+#include "storage/browser/fileapi/file_system_context.h"
+#include "storage/browser/fileapi/file_system_operation.h"
+#include "storage/browser/fileapi/file_system_operation_runner.h"
+#include "storage/browser/fileapi/isolated_context.h"
+#include "storage/common/blob/shareable_file_reference.h"
using apps::AppWindow;
using apps::AppWindowRegistry;
@@ -1072,10 +1072,10 @@ bool DeveloperPrivateLoadDirectoryFunction::RunAsync() {
// Directory url is non empty only for syncfilesystem.
if (directory_url_str != "") {
- fileapi::FileSystemURL directory_url =
+ storage::FileSystemURL directory_url =
context_->CrackURL(GURL(directory_url_str));
if (!directory_url.is_valid() ||
- directory_url.type() != fileapi::kFileSystemTypeSyncable) {
+ directory_url.type() != storage::kFileSystemTypeSyncable) {
SetError("DirectoryEntry of unsupported filesystem.");
return false;
}
@@ -1095,21 +1095,21 @@ bool DeveloperPrivateLoadDirectoryFunction::RunAsync() {
// points to a non-native local directory.
std::string filesystem_id;
bool cracked =
- fileapi::CrackIsolatedFileSystemName(filesystem_name, &filesystem_id);
+ storage::CrackIsolatedFileSystemName(filesystem_name, &filesystem_id);
CHECK(cracked);
base::FilePath virtual_path =
- fileapi::IsolatedContext::GetInstance()
+ storage::IsolatedContext::GetInstance()
->CreateVirtualRootPath(filesystem_id)
.Append(base::FilePath::FromUTF8Unsafe(filesystem_path));
- fileapi::FileSystemURL directory_url = context_->CreateCrackedFileSystemURL(
+ storage::FileSystemURL directory_url = context_->CreateCrackedFileSystemURL(
extensions::Extension::GetBaseURLFromExtensionId(extension_id()),
- fileapi::kFileSystemTypeIsolated,
+ storage::kFileSystemTypeIsolated,
virtual_path);
if (directory_url.is_valid() &&
- directory_url.type() != fileapi::kFileSystemTypeNativeLocal &&
- directory_url.type() != fileapi::kFileSystemTypeRestrictedNativeLocal &&
- directory_url.type() != fileapi::kFileSystemTypeDragged) {
+ directory_url.type() != storage::kFileSystemTypeNativeLocal &&
+ directory_url.type() != storage::kFileSystemTypeRestrictedNativeLocal &&
+ directory_url.type() != storage::kFileSystemTypeDragged) {
return LoadByFileSystemAPI(directory_url);
}
@@ -1120,7 +1120,7 @@ bool DeveloperPrivateLoadDirectoryFunction::RunAsync() {
}
bool DeveloperPrivateLoadDirectoryFunction::LoadByFileSystemAPI(
- const fileapi::FileSystemURL& directory_url) {
+ const storage::FileSystemURL& directory_url) {
std::string directory_url_str = directory_url.ToGURL().spec();
size_t pos = 0;
@@ -1178,7 +1178,7 @@ void DeveloperPrivateLoadDirectoryFunction::ReadDirectoryByFileSystemAPI(
const base::FilePath& project_path,
const base::FilePath& destination_path) {
GURL project_url = GURL(project_base_url_ + destination_path.AsUTF8Unsafe());
- fileapi::FileSystemURL url = context_->CrackURL(project_url);
+ storage::FileSystemURL url = context_->CrackURL(project_url);
context_->operation_runner()->ReadDirectory(
url, base::Bind(&DeveloperPrivateLoadDirectoryFunction::
@@ -1190,9 +1190,8 @@ void DeveloperPrivateLoadDirectoryFunction::ReadDirectoryByFileSystemAPICb(
const base::FilePath& project_path,
const base::FilePath& destination_path,
base::File::Error status,
- const fileapi::FileSystemOperation::FileEntryList& file_list,
+ const storage::FileSystemOperation::FileEntryList& file_list,
bool has_more) {
-
if (status != base::File::FILE_OK) {
DLOG(ERROR) << "Error in copying files from sync filesystem.";
return;
@@ -1216,7 +1215,7 @@ void DeveloperPrivateLoadDirectoryFunction::ReadDirectoryByFileSystemAPICb(
GURL project_url = GURL(project_base_url_ +
destination_path.Append(file_list[i].name).AsUTF8Unsafe());
- fileapi::FileSystemURL url = context_->CrackURL(project_url);
+ storage::FileSystemURL url = context_->CrackURL(project_url);
base::FilePath target_path = project_path;
target_path = target_path.Append(file_list[i].name);
@@ -1247,7 +1246,7 @@ void DeveloperPrivateLoadDirectoryFunction::SnapshotFileCallback(
base::File::Error result,
const base::File::Info& file_info,
const base::FilePath& src_path,
- const scoped_refptr<webkit_blob::ShareableFileReference>& file_ref) {
+ const scoped_refptr<storage::ShareableFileReference>& file_ref) {
if (result != base::File::FILE_OK) {
SetError("Error in copying files from sync filesystem.");
success_ = false;

Powered by Google App Engine
This is Rietveld 408576698