| Index: third_party/WebKit/Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp
|
| diff --git a/third_party/WebKit/Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp b/third_party/WebKit/Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp
|
| index 392bfa072fbb9479ce43f448f015c430315f6eb4..b0003ac8107acf2879207a431d823b3ad146b783 100644
|
| --- a/third_party/WebKit/Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp
|
| +++ b/third_party/WebKit/Source/modules/filesystem/WorkerGlobalScopeFileSystem.cpp
|
| @@ -31,12 +31,12 @@
|
| #include "core/dom/ExceptionCode.h"
|
| #include "core/fileapi/FileError.h"
|
| #include "core/workers/WorkerGlobalScope.h"
|
| -#include "modules/filesystem/DOMFileSystemBase.h"
|
| -#include "modules/filesystem/DirectoryEntrySync.h"
|
| #include "modules/filesystem/ErrorCallback.h"
|
| -#include "modules/filesystem/FileEntrySync.h"
|
| +#include "modules/filesystem/FileSystemBase.h"
|
| #include "modules/filesystem/FileSystemCallback.h"
|
| #include "modules/filesystem/FileSystemCallbacks.h"
|
| +#include "modules/filesystem/FileSystemDirectoryEntrySync.h"
|
| +#include "modules/filesystem/FileSystemFileEntrySync.h"
|
| #include "modules/filesystem/LocalFileSystem.h"
|
| #include "modules/filesystem/SyncCallbackHelper.h"
|
| #include "platform/FileSystemType.h"
|
| @@ -53,17 +53,15 @@ void WorkerGlobalScopeFileSystem::webkitRequestFileSystem(
|
| ErrorCallback* errorCallback) {
|
| ExecutionContext* secureContext = worker.getExecutionContext();
|
| if (!secureContext->getSecurityOrigin()->canAccessFileSystem()) {
|
| - DOMFileSystem::reportError(&worker,
|
| - ScriptErrorCallback::wrap(errorCallback),
|
| - FileError::kSecurityErr);
|
| + FileSystem::reportError(&worker, ScriptErrorCallback::wrap(errorCallback),
|
| + FileError::kSecurityErr);
|
| return;
|
| }
|
|
|
| FileSystemType fileSystemType = static_cast<FileSystemType>(type);
|
| - if (!DOMFileSystemBase::isValidType(fileSystemType)) {
|
| - DOMFileSystem::reportError(&worker,
|
| - ScriptErrorCallback::wrap(errorCallback),
|
| - FileError::kInvalidModificationErr);
|
| + if (!FileSystemBase::isValidType(fileSystemType)) {
|
| + FileSystem::reportError(&worker, ScriptErrorCallback::wrap(errorCallback),
|
| + FileError::kInvalidModificationErr);
|
| return;
|
| }
|
|
|
| @@ -74,7 +72,7 @@ void WorkerGlobalScopeFileSystem::webkitRequestFileSystem(
|
| &worker, fileSystemType));
|
| }
|
|
|
| -DOMFileSystemSync* WorkerGlobalScopeFileSystem::webkitRequestFileSystemSync(
|
| +FileSystemSync* WorkerGlobalScopeFileSystem::webkitRequestFileSystemSync(
|
| WorkerGlobalScope& worker,
|
| int type,
|
| long long size,
|
| @@ -86,7 +84,7 @@ DOMFileSystemSync* WorkerGlobalScopeFileSystem::webkitRequestFileSystemSync(
|
| }
|
|
|
| FileSystemType fileSystemType = static_cast<FileSystemType>(type);
|
| - if (!DOMFileSystemBase::isValidType(fileSystemType)) {
|
| + if (!FileSystemBase::isValidType(fileSystemType)) {
|
| exceptionState.throwDOMException(
|
| InvalidModificationError,
|
| "the type must be kTemporary or kPersistent.");
|
| @@ -108,22 +106,20 @@ DOMFileSystemSync* WorkerGlobalScopeFileSystem::webkitRequestFileSystemSync(
|
| void WorkerGlobalScopeFileSystem::webkitResolveLocalFileSystemURL(
|
| WorkerGlobalScope& worker,
|
| const String& url,
|
| - EntryCallback* successCallback,
|
| + FileSystemEntryCallback* successCallback,
|
| ErrorCallback* errorCallback) {
|
| KURL completedURL = worker.completeURL(url);
|
| ExecutionContext* secureContext = worker.getExecutionContext();
|
| if (!secureContext->getSecurityOrigin()->canAccessFileSystem() ||
|
| !secureContext->getSecurityOrigin()->canRequest(completedURL)) {
|
| - DOMFileSystem::reportError(&worker,
|
| - ScriptErrorCallback::wrap(errorCallback),
|
| - FileError::kSecurityErr);
|
| + FileSystem::reportError(&worker, ScriptErrorCallback::wrap(errorCallback),
|
| + FileError::kSecurityErr);
|
| return;
|
| }
|
|
|
| if (!completedURL.isValid()) {
|
| - DOMFileSystem::reportError(&worker,
|
| - ScriptErrorCallback::wrap(errorCallback),
|
| - FileError::kEncodingErr);
|
| + FileSystem::reportError(&worker, ScriptErrorCallback::wrap(errorCallback),
|
| + FileError::kEncodingErr);
|
| return;
|
| }
|
|
|
| @@ -133,7 +129,8 @@ void WorkerGlobalScopeFileSystem::webkitResolveLocalFileSystemURL(
|
| successCallback, ScriptErrorCallback::wrap(errorCallback), &worker));
|
| }
|
|
|
| -EntrySync* WorkerGlobalScopeFileSystem::webkitResolveLocalFileSystemSyncURL(
|
| +FileSystemEntrySync*
|
| +WorkerGlobalScopeFileSystem::webkitResolveLocalFileSystemSyncURL(
|
| WorkerGlobalScope& worker,
|
| const String& url,
|
| ExceptionState& exceptionState) {
|
|
|