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

Unified Diff: third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp

Issue 2939773005: [POC] Implement "module responses map" concept (Closed)
Patch Set: rebase Created 3 years, 5 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 | « no previous file | third_party/WebKit/Source/core/loader/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp
diff --git a/third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp b/third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp
index 71ffa46bb5884591ba1106ff7f10f88fc43efe64..49869ca12c78685df7097b23b41dab53296abeda 100644
--- a/third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp
+++ b/third_party/WebKit/Source/core/dom/TaskRunnerHelper.cpp
@@ -80,10 +80,6 @@ RefPtr<WebTaskRunner> TaskRunnerHelper::Get(
return Get(type, ToDocument(execution_context));
if (execution_context->IsDocument())
return Get(type, ToDocument(execution_context));
- if (execution_context->IsMainThreadWorkletGlobalScope()) {
- return Get(type,
- ToMainThreadWorkletGlobalScope(execution_context)->GetFrame());
- }
if (execution_context->IsWorkerOrWorkletGlobalScope())
return Get(type, ToWorkerOrWorkletGlobalScope(execution_context));
execution_context = nullptr;
@@ -101,6 +97,8 @@ RefPtr<WebTaskRunner> TaskRunnerHelper::Get(
WorkerOrWorkletGlobalScope* global_scope) {
DCHECK(global_scope);
DCHECK(global_scope->IsContextThread());
+ if (global_scope->IsMainThreadWorkletGlobalScope())
+ return Get(type, ToMainThreadWorkletGlobalScope(global_scope)->GetFrame());
return Get(type, global_scope->GetThread());
}
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/loader/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698