| Index: third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
|
| diff --git a/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp b/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
|
| index 77df99ec57b377fd1ce1b346d619c5c82849c293..24cdbc7ce0315d9d3f835e94d43af137b7d4e194 100644
|
| --- a/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
|
| +++ b/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
|
| @@ -30,15 +30,17 @@
|
|
|
| #include "web/ServiceWorkerGlobalScopeProxy.h"
|
|
|
| +#include <memory>
|
| +#include <utility>
|
| #include "bindings/core/v8/SourceLocation.h"
|
| #include "bindings/core/v8/WorkerOrWorkletScriptController.h"
|
| #include "core/dom/Document.h"
|
| #include "core/dom/ExecutionContext.h"
|
| #include "core/dom/ExecutionContextTask.h"
|
| #include "core/dom/MessagePort.h"
|
| +#include "core/dom/TaskRunnerHelper.h"
|
| #include "core/inspector/ConsoleMessage.h"
|
| #include "core/origin_trials/OriginTrials.h"
|
| -#include "core/workers/ParentFrameTaskRunners.h"
|
| #include "core/workers/WorkerGlobalScope.h"
|
| #include "core/workers/WorkerThread.h"
|
| #include "modules/background_sync/SyncEvent.h"
|
| @@ -70,8 +72,6 @@
|
| #include "wtf/Assertions.h"
|
| #include "wtf/Functional.h"
|
| #include "wtf/PtrUtil.h"
|
| -#include <memory>
|
| -#include <utility>
|
|
|
| namespace blink {
|
|
|
| @@ -89,7 +89,6 @@ ServiceWorkerGlobalScopeProxy::~ServiceWorkerGlobalScopeProxy() {
|
|
|
| DEFINE_TRACE(ServiceWorkerGlobalScopeProxy) {
|
| visitor->trace(m_document);
|
| - visitor->trace(m_parentFrameTaskRunners);
|
| visitor->trace(m_pendingPreloadFetchEvents);
|
| }
|
|
|
| @@ -390,7 +389,7 @@ void ServiceWorkerGlobalScopeProxy::postMessageToPageInspector(
|
| DCHECK(m_embeddedWorker);
|
| // The TaskType of Inspector tasks need to be Unthrottled because they need to
|
| // run even on a suspended page.
|
| - m_parentFrameTaskRunners->get(TaskType::Unthrottled)
|
| + FrameTaskRunnerHelper::get(TaskType::Unthrottled, m_workerGlobalScope.get())
|
| ->postTask(
|
| BLINK_FROM_HERE,
|
| crossThreadBind(&WebEmbeddedWorkerImpl::postMessageToPageInspector,
|
| @@ -457,13 +456,6 @@ ServiceWorkerGlobalScopeProxy::ServiceWorkerGlobalScopeProxy(
|
| m_document(&document),
|
| m_client(&client),
|
| m_workerGlobalScope(nullptr) {
|
| - // ServiceWorker can sometimes run tasks that are initiated by/associated with
|
| - // a document's frame but these documents can be from a different process. So
|
| - // we intentionally populate the task runners with null document in order to
|
| - // use the thread's default task runner. Note that |m_document| should not be
|
| - // used as it's a dummy document for loading that doesn't represent the frame
|
| - // of any associated document.
|
| - m_parentFrameTaskRunners = ParentFrameTaskRunners::create(nullptr);
|
| }
|
|
|
| void ServiceWorkerGlobalScopeProxy::detach() {
|
|
|