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

Unified Diff: third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp

Issue 2656343002: Replace [CallWith=ExecutionContext] with [CallWith=ScriptState] (Closed)
Patch Set: Few more Created 3 years, 11 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: third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp
diff --git a/third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp b/third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp
index 23367b36508ab7af91aa5e70702cad6a333df792..ed923d45e7306a60257b5b87f6dab2878ee0d471 100644
--- a/third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp
+++ b/third_party/WebKit/Source/modules/quota/DeprecatedStorageInfo.cpp
@@ -30,8 +30,8 @@
#include "modules/quota/DeprecatedStorageInfo.h"
+#include "bindings/core/v8/ScriptState.h"
#include "core/dom/ExceptionCode.h"
-#include "core/dom/ExecutionContext.h"
#include "core/dom/TaskRunnerHelper.h"
#include "modules/quota/DeprecatedStorageQuota.h"
#include "modules/quota/StorageErrorCallback.h"
@@ -44,7 +44,7 @@ namespace blink {
DeprecatedStorageInfo::DeprecatedStorageInfo() {}
void DeprecatedStorageInfo::queryUsageAndQuota(
- ExecutionContext* executionContext,
+ ScriptState* scriptState,
int storageType,
StorageUsageCallback* successCallback,
StorageErrorCallback* errorCallback) {
@@ -53,16 +53,16 @@ void DeprecatedStorageInfo::queryUsageAndQuota(
DeprecatedStorageQuota* storageQuota = getStorageQuota(storageType);
if (!storageQuota) {
// Unknown storage type is requested.
- executionContext->postTask(TaskType::MiscPlatformAPI, BLINK_FROM_HERE,
- StorageErrorCallback::createSameThreadTask(
- errorCallback, NotSupportedError));
+ scriptState->getExecutionContext()->postTask(
+ TaskType::MiscPlatformAPI, BLINK_FROM_HERE,
+ StorageErrorCallback::createSameThreadTask(errorCallback,
+ NotSupportedError));
return;
}
- storageQuota->queryUsageAndQuota(executionContext, successCallback,
- errorCallback);
+ storageQuota->queryUsageAndQuota(scriptState, successCallback, errorCallback);
}
-void DeprecatedStorageInfo::requestQuota(ExecutionContext* executionContext,
+void DeprecatedStorageInfo::requestQuota(ScriptState* scriptState,
int storageType,
unsigned long long newQuotaInBytes,
StorageQuotaCallback* successCallback,
@@ -72,12 +72,13 @@ void DeprecatedStorageInfo::requestQuota(ExecutionContext* executionContext,
DeprecatedStorageQuota* storageQuota = getStorageQuota(storageType);
if (!storageQuota) {
// Unknown storage type is requested.
- executionContext->postTask(TaskType::MiscPlatformAPI, BLINK_FROM_HERE,
- StorageErrorCallback::createSameThreadTask(
- errorCallback, NotSupportedError));
+ scriptState->getExecutionContext()->postTask(
+ TaskType::MiscPlatformAPI, BLINK_FROM_HERE,
+ StorageErrorCallback::createSameThreadTask(errorCallback,
+ NotSupportedError));
return;
}
- storageQuota->requestQuota(executionContext, newQuotaInBytes, successCallback,
+ storageQuota->requestQuota(scriptState, newQuotaInBytes, successCallback,
errorCallback);
}

Powered by Google App Engine
This is Rietveld 408576698