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

Unified Diff: Source/modules/serviceworkers/ServiceWorkerClients.cpp

Issue 1240763002: CallbackPromiseAdapter types should be more compatible with WebCallbacks (3/3). (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 5 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: Source/modules/serviceworkers/ServiceWorkerClients.cpp
diff --git a/Source/modules/serviceworkers/ServiceWorkerClients.cpp b/Source/modules/serviceworkers/ServiceWorkerClients.cpp
index b72880f27a8c5195264a2ed556282bc3e10a303a..e7d2b154c441f967c6d75976afeb326da7bc3f05 100644
--- a/Source/modules/serviceworkers/ServiceWorkerClients.cpp
+++ b/Source/modules/serviceworkers/ServiceWorkerClients.cpp
@@ -16,7 +16,6 @@
#include "modules/serviceworkers/ServiceWorkerWindowClient.h"
#include "public/platform/WebServiceWorkerClientQueryOptions.h"
#include "public/platform/WebServiceWorkerClientsInfo.h"
-#include "wtf/OwnPtr.h"
#include "wtf/PassOwnPtr.h"
#include "wtf/RefPtr.h"
#include "wtf/Vector.h"
@@ -27,12 +26,12 @@ namespace {
class ClientArray {
public:
- using WebType = OwnPtr<WebServiceWorkerClientsInfo>;
- static HeapVector<Member<ServiceWorkerClient>> take(ScriptPromiseResolver*, PassOwnPtr<WebServiceWorkerClientsInfo> webClients)
+ using WebType = const WebServiceWorkerClientsInfo&;
+ static HeapVector<Member<ServiceWorkerClient>> take(ScriptPromiseResolver*, const WebServiceWorkerClientsInfo& webClients)
{
HeapVector<Member<ServiceWorkerClient>> clients;
- for (size_t i = 0; i < webClients->clients.size(); ++i) {
- const WebServiceWorkerClientInfo& client = webClients->clients[i];
+ for (size_t i = 0; i < webClients.clients.size(); ++i) {
+ const WebServiceWorkerClientInfo& client = webClients.clients[i];
if (client.clientType == WebServiceWorkerClientTypeWindow)
clients.append(ServiceWorkerWindowClient::create(client));
else

Powered by Google App Engine
This is Rietveld 408576698