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

Unified Diff: third_party/WebKit/public/web/modules/serviceworker/WebServiceWorkerContextClient.h

Issue 2480293004: Mandate unique_ptr for base::IDMap in IDMapOwnPointer mode. (Closed)
Patch Set: Rebase Created 4 years, 1 month 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/public/web/modules/serviceworker/WebServiceWorkerContextClient.h
diff --git a/third_party/WebKit/public/web/modules/serviceworker/WebServiceWorkerContextClient.h b/third_party/WebKit/public/web/modules/serviceworker/WebServiceWorkerContextClient.h
index cdf5b2b5b74ba580b2f5e83b18f9ba7b9bcb1df5..7d770cf11710038c1db26b365821bdf4a989ca47 100644
--- a/third_party/WebKit/public/web/modules/serviceworker/WebServiceWorkerContextClient.h
+++ b/third_party/WebKit/public/web/modules/serviceworker/WebServiceWorkerContextClient.h
@@ -38,6 +38,8 @@
#include "public/platform/modules/serviceworker/WebServiceWorkerEventResult.h"
#include "public/platform/modules/serviceworker/WebServiceWorkerSkipWaitingCallbacks.h"
#include "public/web/WebDevToolsAgentClient.h"
+#include <memory>
+#include <utility>
danakj 2016/11/30 00:34:01 same
#include <v8.h>
namespace blink {
@@ -207,20 +209,22 @@ class WebServiceWorkerContextClient {
// WebServiceWorkerClientInfo and WebServiceWorkerError ownerships are
// passed to the WebServiceWorkerClientCallbacks implementation.
virtual void getClient(const WebString&,
- WebServiceWorkerClientCallbacks*) = 0;
+ std::unique_ptr<WebServiceWorkerClientCallbacks>) = 0;
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after calling either onSuccess or onError.
// WebServiceWorkerClientsInfo and WebServiceWorkerError ownerships are
// passed to the WebServiceWorkerClientsCallbacks implementation.
- virtual void getClients(const WebServiceWorkerClientQueryOptions&,
- WebServiceWorkerClientsCallbacks*) = 0;
+ virtual void getClients(
+ const WebServiceWorkerClientQueryOptions&,
+ std::unique_ptr<WebServiceWorkerClientsCallbacks>) = 0;
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after calling either onSuccess or onError.
// WebServiceWorkerClientInfo and WebServiceWorkerError ownerships are
// passed to the WebServiceWorkerClientsCallbacks implementation.
- virtual void openWindow(const WebURL&, WebServiceWorkerClientCallbacks*) = 0;
+ virtual void openWindow(const WebURL&,
+ std::unique_ptr<WebServiceWorkerClientCallbacks>) = 0;
// A suggestion to cache this metadata in association with this URL.
virtual void setCachedMetadata(const WebURL& url,
@@ -245,16 +249,18 @@ class WebServiceWorkerContextClient {
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after run.
- virtual void skipWaiting(WebServiceWorkerSkipWaitingCallbacks*) = 0;
+ virtual void skipWaiting(
+ std::unique_ptr<WebServiceWorkerSkipWaitingCallbacks>) = 0;
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after run.
- virtual void claim(WebServiceWorkerClientsClaimCallbacks*) = 0;
+ virtual void claim(
+ std::unique_ptr<WebServiceWorkerClientsClaimCallbacks>) = 0;
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callback after calling either onSuccess or onError.
virtual void focus(const WebString& uuid,
- WebServiceWorkerClientCallbacks*) = 0;
+ std::unique_ptr<WebServiceWorkerClientCallbacks>) = 0;
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after calling either onSuccess or onError.
@@ -262,7 +268,7 @@ class WebServiceWorkerContextClient {
// passed to the WebServiceWorkerClientsCallbacks implementation.
virtual void navigate(const WebString& uuid,
const WebURL&,
- WebServiceWorkerClientCallbacks*) = 0;
+ std::unique_ptr<WebServiceWorkerClientCallbacks>) = 0;
// Called when the worker wants to register subscopes to handle via foreign
// fetch. Will only be called while an install event is in progress.

Powered by Google App Engine
This is Rietveld 408576698