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

Unified Diff: third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 years, 6 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/web/WebSharedWorkerImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp b/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp
index 5060946d4ef6b4d8cca8677f879a6ad7bdc0be25..51b411cf23a1dfaa26445fcf5d640a069576b353 100644
--- a/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp
+++ b/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp
@@ -72,6 +72,8 @@
#include "web/WebLocalFrameImpl.h"
#include "web/WorkerContentSettingsClient.h"
#include "wtf/Functional.h"
+#include "wtf/PtrUtil.h"
+#include <memory>
namespace blink {
@@ -170,7 +172,7 @@ void WebSharedWorkerImpl::didFinishDocumentLoad(WebLocalFrame* frame)
{
DCHECK(!m_loadingDocument);
DCHECK(!m_mainScriptLoader);
- m_networkProvider = adoptPtr(m_client->createServiceWorkerNetworkProvider(frame->dataSource()));
+ m_networkProvider = wrapUnique(m_client->createServiceWorkerNetworkProvider(frame->dataSource()));
m_mainScriptLoader = WorkerScriptLoader::create();
m_mainScriptLoader->setRequestContext(WebURLRequest::RequestContextSharedWorker);
m_loadingDocument = toWebLocalFrameImpl(frame)->frame()->document();
@@ -217,7 +219,7 @@ WebDevToolsAgentClient::WebKitClientMessageLoop* WebSharedWorkerImpl::createClie
// WorkerReportingProxy --------------------------------------------------------
-void WebSharedWorkerImpl::reportException(const String& errorMessage, PassOwnPtr<SourceLocation>)
+void WebSharedWorkerImpl::reportException(const String& errorMessage, std::unique_ptr<SourceLocation>)
{
// Not suppported in SharedWorker.
}
@@ -331,11 +333,11 @@ void WebSharedWorkerImpl::onScriptLoaderFinished()
WorkerClients* workerClients = WorkerClients::create();
provideLocalFileSystemToWorker(workerClients, LocalFileSystemClient::create());
WebSecurityOrigin webSecurityOrigin(m_loadingDocument->getSecurityOrigin());
- provideContentSettingsClientToWorker(workerClients, adoptPtr(m_client->createWorkerContentSettingsClientProxy(webSecurityOrigin)));
+ provideContentSettingsClientToWorker(workerClients, wrapUnique(m_client->createWorkerContentSettingsClientProxy(webSecurityOrigin)));
provideIndexedDBClientToWorker(workerClients, IndexedDBClientImpl::create());
ContentSecurityPolicy* contentSecurityPolicy = m_mainScriptLoader->releaseContentSecurityPolicy();
WorkerThreadStartMode startMode = m_workerInspectorProxy->workerStartMode(document);
- OwnPtr<WorkerThreadStartupData> startupData = WorkerThreadStartupData::create(
+ std::unique_ptr<WorkerThreadStartupData> startupData = WorkerThreadStartupData::create(
m_url,
m_loadingDocument->userAgent(),
m_mainScriptLoader->script(),
« no previous file with comments | « third_party/WebKit/Source/web/WebSharedWorkerImpl.h ('k') | third_party/WebKit/Source/web/WebStorageEventDispatcherImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698