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

Unified Diff: Source/web/StorageQuotaClientImpl.cpp

Issue 676183002: Oilpan: simplify quota storage callbacks objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « Source/web/StorageQuotaClientImpl.h ('k') | public/platform/WebStorageQuotaCallbacks.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/StorageQuotaClientImpl.cpp
diff --git a/Source/web/StorageQuotaClientImpl.cpp b/Source/web/StorageQuotaClientImpl.cpp
index ca888c80ccfbc90f08933f946a8833e86b959355..b8faf70685b240a08db5dd55b95530b7d158bd54 100644
--- a/Source/web/StorageQuotaClientImpl.cpp
+++ b/Source/web/StorageQuotaClientImpl.cpp
@@ -50,9 +50,8 @@
namespace blink {
-PassOwnPtrWillBeRawPtr<StorageQuotaClientImpl> StorageQuotaClientImpl::create()
+StorageQuotaClientImpl::StorageQuotaClientImpl()
{
- return adoptPtrWillBeNoop(new StorageQuotaClientImpl());
}
StorageQuotaClientImpl::~StorageQuotaClientImpl()
@@ -66,8 +65,8 @@ void StorageQuotaClientImpl::requestQuota(ExecutionContext* executionContext, We
if (executionContext->isDocument()) {
Document* document = toDocument(executionContext);
WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(document->frame());
- OwnPtrWillBeRawPtr<StorageQuotaCallbacks> callbacks = DeprecatedStorageQuotaCallbacksImpl::create(successCallback, errorCallback);
- webFrame->client()->requestStorageQuota(webFrame, storageType, newQuotaInBytes, callbacks.release());
+ StorageQuotaCallbacks* callbacks = DeprecatedStorageQuotaCallbacksImpl::create(successCallback, errorCallback);
+ webFrame->client()->requestStorageQuota(webFrame, storageType, newQuotaInBytes, callbacks);
} else {
// Requesting quota in Worker is not supported.
executionContext->postTask(StorageErrorCallback::CallbackTask::create(errorCallback, NotSupportedError));
@@ -82,8 +81,8 @@ ScriptPromise StorageQuotaClientImpl::requestPersistentQuota(ScriptState* script
if (scriptState->executionContext()->isDocument()) {
Document* document = toDocument(scriptState->executionContext());
WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(document->frame());
- OwnPtrWillBeRawPtr<StorageQuotaCallbacks> callbacks = StorageQuotaCallbacksImpl::create(resolver);
- webFrame->client()->requestStorageQuota(webFrame, WebStorageQuotaTypePersistent, newQuotaInBytes, callbacks.release());
+ StorageQuotaCallbacks* callbacks = StorageQuotaCallbacksImpl::create(resolver);
+ webFrame->client()->requestStorageQuota(webFrame, WebStorageQuotaTypePersistent, newQuotaInBytes, callbacks);
} else {
// Requesting quota in Worker is not supported.
resolver->reject(DOMError::create(NotSupportedError));
@@ -92,8 +91,4 @@ ScriptPromise StorageQuotaClientImpl::requestPersistentQuota(ScriptState* script
return promise;
}
-StorageQuotaClientImpl::StorageQuotaClientImpl()
-{
-}
-
} // namespace blink
« no previous file with comments | « Source/web/StorageQuotaClientImpl.h ('k') | public/platform/WebStorageQuotaCallbacks.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698