Index: third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp |
diff --git a/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp b/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp |
index 9b2a552d4db9bebe7c47fb93db6efe6e10da3c87..e23768fac3cea494a95e5368cb3a70985947d62b 100644 |
--- a/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp |
+++ b/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp |
@@ -49,7 +49,6 @@ |
#include "core/workers/WorkerContentSettingsClient.h" |
#include "core/workers/WorkerGlobalScope.h" |
#include "core/workers/WorkerInspectorProxy.h" |
-#include "core/workers/WorkerLoaderProxy.h" |
#include "core/workers/WorkerScriptLoader.h" |
#include "core/workers/WorkerThreadStartupData.h" |
#include "platform/CrossThreadFunctional.h" |
@@ -102,8 +101,6 @@ WebSharedWorkerImpl::~WebSharedWorkerImpl() { |
web_view_->Close(); |
main_frame_->Close(); |
- if (loader_proxy_) |
- loader_proxy_->DetachProvider(this); |
} |
void WebSharedWorkerImpl::TerminateWorkerThread() { |
@@ -252,14 +249,6 @@ void WebSharedWorkerImpl::DidTerminateWorkerThread() { |
delete this; |
} |
-ThreadableLoadingContext* WebSharedWorkerImpl::GetThreadableLoadingContext() { |
- if (!loading_context_) { |
- loading_context_ = |
- ThreadableLoadingContext::Create(*ToDocument(loading_document_.Get())); |
- } |
- return loading_context_; |
-} |
- |
void WebSharedWorkerImpl::Connect( |
std::unique_ptr<WebMessagePortChannel> web_channel) { |
DCHECK(IsMainThread()); |
@@ -384,10 +373,11 @@ void WebSharedWorkerImpl::OnScriptLoaderFinished() { |
ParentFrameTaskRunners* task_runners = |
ParentFrameTaskRunners::Create(nullptr); |
- loader_proxy_ = WorkerLoaderProxy::Create(this); |
reporting_proxy_ = new WebSharedWorkerReportingProxyImpl(this, task_runners); |
- worker_thread_ = |
- SharedWorkerThread::Create(name_, loader_proxy_, *reporting_proxy_); |
+ worker_thread_ = WTF::MakeUnique<SharedWorkerThread>( |
+ name_, |
+ ThreadableLoadingContext::Create(*ToDocument(loading_document_.Get())), |
+ *reporting_proxy_); |
probe::scriptImported(loading_document_, main_script_loader_->Identifier(), |
main_script_loader_->SourceText()); |
main_script_loader_.Clear(); |