| Index: trunk/src/chrome/browser/chromeos/extensions/file_system_provider/file_system_provider_api.cc
|
| ===================================================================
|
| --- trunk/src/chrome/browser/chromeos/extensions/file_system_provider/file_system_provider_api.cc (revision 278185)
|
| +++ trunk/src/chrome/browser/chromeos/extensions/file_system_provider/file_system_provider_api.cc (working copy)
|
| @@ -97,6 +97,15 @@
|
| return true;
|
| }
|
|
|
| +bool FileSystemProviderInternalUnmountRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::UnmountRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| + EXTENSION_FUNCTION_VALIDATE(params);
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| + return true;
|
| +}
|
| +
|
| bool
|
| FileSystemProviderInternalGetMetadataRequestedSuccessFunction::RunWhenValid() {
|
| using api::file_system_provider_internal::GetMetadataRequestedSuccess::Params;
|
| @@ -108,6 +117,16 @@
|
| return true;
|
| }
|
|
|
| +bool
|
| +FileSystemProviderInternalGetMetadataRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::GetMetadataRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| + EXTENSION_FUNCTION_VALIDATE(params);
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| + return true;
|
| +}
|
| +
|
| bool FileSystemProviderInternalReadDirectoryRequestedSuccessFunction::
|
| RunWhenValid() {
|
| using api::file_system_provider_internal::ReadDirectoryRequestedSuccess::
|
| @@ -122,6 +141,16 @@
|
| }
|
|
|
| bool
|
| +FileSystemProviderInternalReadDirectoryRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::ReadDirectoryRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| + EXTENSION_FUNCTION_VALIDATE(params);
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| + return true;
|
| +}
|
| +
|
| +bool
|
| FileSystemProviderInternalOpenFileRequestedSuccessFunction::RunWhenValid() {
|
| using api::file_system_provider_internal::OpenFileRequestedSuccess::Params;
|
| scoped_ptr<Params> params(Params::Create(*args_));
|
| @@ -132,6 +161,15 @@
|
| return true;
|
| }
|
|
|
| +bool FileSystemProviderInternalOpenFileRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::OpenFileRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| + EXTENSION_FUNCTION_VALIDATE(params);
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| + return true;
|
| +}
|
| +
|
| bool
|
| FileSystemProviderInternalCloseFileRequestedSuccessFunction::RunWhenValid() {
|
| using api::file_system_provider_internal::CloseFileRequestedSuccess::Params;
|
| @@ -143,6 +181,15 @@
|
| return true;
|
| }
|
|
|
| +bool FileSystemProviderInternalCloseFileRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::CloseFileRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| + EXTENSION_FUNCTION_VALIDATE(params);
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| + return true;
|
| +}
|
| +
|
| bool
|
| FileSystemProviderInternalReadFileRequestedSuccessFunction::RunWhenValid() {
|
| using api::file_system_provider_internal::ReadFileRequestedSuccess::Params;
|
| @@ -155,12 +202,12 @@
|
| return true;
|
| }
|
|
|
| -bool FileSystemProviderInternalOperationRequestedErrorFunction::RunWhenValid() {
|
| - using api::file_system_provider_internal::OperationRequestedError::Params;
|
| - scoped_ptr<Params> params(Params::Create(*args_));
|
| +bool FileSystemProviderInternalReadFileRequestedErrorFunction::RunWhenValid() {
|
| + using api::file_system_provider_internal::ReadFileRequestedError::Params;
|
| + const scoped_ptr<Params> params(Params::Create(*args_));
|
| EXTENSION_FUNCTION_VALIDATE(params);
|
| - RejectRequest(RequestValue::CreateForOperationError(params.Pass()),
|
| - ProviderErrorToFileError(params->error));
|
| +
|
| + RejectRequest(ProviderErrorToFileError(params->error));
|
| return true;
|
| }
|
|
|
|
|