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

Unified Diff: third_party/WebKit/Source/core/workers/SharedWorkerGlobalScope.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/core/workers/SharedWorkerGlobalScope.cpp
diff --git a/third_party/WebKit/Source/core/workers/SharedWorkerGlobalScope.cpp b/third_party/WebKit/Source/core/workers/SharedWorkerGlobalScope.cpp
index b299a8068bb8bfba09e06fa18c773e07fe6acc2a..e3fd264bb6a3998ca4287c40e867d5dbef077f47 100644
--- a/third_party/WebKit/Source/core/workers/SharedWorkerGlobalScope.cpp
+++ b/third_party/WebKit/Source/core/workers/SharedWorkerGlobalScope.cpp
@@ -32,12 +32,13 @@
#include "bindings/core/v8/SourceLocation.h"
#include "core/events/MessageEvent.h"
-#include "core/inspector/ConsoleMessage.h"
#include "core/frame/LocalDOMWindow.h"
+#include "core/inspector/ConsoleMessage.h"
#include "core/origin_trials/OriginTrialContext.h"
#include "core/workers/SharedWorkerThread.h"
#include "core/workers/WorkerClients.h"
#include "wtf/CurrentTime.h"
+#include <memory>
namespace blink {
@@ -49,7 +50,7 @@ MessageEvent* createConnectEvent(MessagePort* port)
}
// static
-SharedWorkerGlobalScope* SharedWorkerGlobalScope::create(const String& name, SharedWorkerThread* thread, PassOwnPtr<WorkerThreadStartupData> startupData)
+SharedWorkerGlobalScope* SharedWorkerGlobalScope::create(const String& name, SharedWorkerThread* thread, std::unique_ptr<WorkerThreadStartupData> startupData)
{
// Note: startupData is finalized on return. After the relevant parts has been
// passed along to the created 'context'.
@@ -60,7 +61,7 @@ SharedWorkerGlobalScope* SharedWorkerGlobalScope::create(const String& name, Sha
return context;
}
-SharedWorkerGlobalScope::SharedWorkerGlobalScope(const String& name, const KURL& url, const String& userAgent, SharedWorkerThread* thread, PassOwnPtr<SecurityOrigin::PrivilegeData> starterOriginPrivilegeData, WorkerClients* workerClients)
+SharedWorkerGlobalScope::SharedWorkerGlobalScope(const String& name, const KURL& url, const String& userAgent, SharedWorkerThread* thread, std::unique_ptr<SecurityOrigin::PrivilegeData> starterOriginPrivilegeData, WorkerClients* workerClients)
: WorkerGlobalScope(url, userAgent, thread, monotonicallyIncreasingTime(), std::move(starterOriginPrivilegeData), workerClients)
, m_name(name)
{
@@ -80,7 +81,7 @@ SharedWorkerThread* SharedWorkerGlobalScope::thread()
return static_cast<SharedWorkerThread*>(Base::thread());
}
-void SharedWorkerGlobalScope::logExceptionToConsole(const String& errorMessage, PassOwnPtr<SourceLocation> location)
+void SharedWorkerGlobalScope::logExceptionToConsole(const String& errorMessage, std::unique_ptr<SourceLocation> location)
{
WorkerGlobalScope::logExceptionToConsole(errorMessage, location->clone());
ConsoleMessage* consoleMessage = ConsoleMessage::create(JSMessageSource, ErrorMessageLevel, errorMessage, std::move(location));

Powered by Google App Engine
This is Rietveld 408576698