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

Unified Diff: third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerRegistration.h

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/modules/serviceworkers/ServiceWorkerRegistration.h
diff --git a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerRegistration.h b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerRegistration.h
index 1368c7e5c9d9ff85035d418ce64792ac43f7d670..bff04eb6ab298ae15fca06e4f3ea26382839d74a 100644
--- a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerRegistration.h
+++ b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerRegistration.h
@@ -15,7 +15,7 @@
#include "public/platform/modules/serviceworker/WebServiceWorkerRegistration.h"
#include "public/platform/modules/serviceworker/WebServiceWorkerRegistrationProxy.h"
#include "wtf/Forward.h"
-#include "wtf/OwnPtr.h"
+#include <memory>
namespace blink {
@@ -48,7 +48,7 @@ public:
// Returns an existing registration object for the handle if it exists.
// Otherwise, returns a new registration object.
- static ServiceWorkerRegistration* getOrCreate(ExecutionContext*, PassOwnPtr<WebServiceWorkerRegistration::Handle>);
+ static ServiceWorkerRegistration* getOrCreate(ExecutionContext*, std::unique_ptr<WebServiceWorkerRegistration::Handle>);
ServiceWorker* installing() { return m_installing; }
ServiceWorker* waiting() { return m_waiting; }
@@ -68,7 +68,7 @@ public:
DECLARE_VIRTUAL_TRACE();
private:
- ServiceWorkerRegistration(ExecutionContext*, PassOwnPtr<WebServiceWorkerRegistration::Handle>);
+ ServiceWorkerRegistration(ExecutionContext*, std::unique_ptr<WebServiceWorkerRegistration::Handle>);
void dispose();
// ActiveScriptWrappable overrides.
@@ -78,7 +78,7 @@ private:
void stop() override;
// A handle to the registration representation in the embedder.
- OwnPtr<WebServiceWorkerRegistration::Handle> m_handle;
+ std::unique_ptr<WebServiceWorkerRegistration::Handle> m_handle;
Member<ServiceWorker> m_installing;
Member<ServiceWorker> m_waiting;
@@ -90,7 +90,7 @@ private:
class ServiceWorkerRegistrationArray {
STATIC_ONLY(ServiceWorkerRegistrationArray);
public:
- static HeapVector<Member<ServiceWorkerRegistration>> take(ScriptPromiseResolver* resolver, Vector<OwnPtr<WebServiceWorkerRegistration::Handle>>* webServiceWorkerRegistrations)
+ static HeapVector<Member<ServiceWorkerRegistration>> take(ScriptPromiseResolver* resolver, Vector<std::unique_ptr<WebServiceWorkerRegistration::Handle>>* webServiceWorkerRegistrations)
{
HeapVector<Member<ServiceWorkerRegistration>> registrations;
for (auto& registration : *webServiceWorkerRegistrations)

Powered by Google App Engine
This is Rietveld 408576698