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

Side by Side Diff: third_party/WebKit/Source/modules/serviceworkers/ExtendableMessageEvent.cpp

Issue 2761693002: Wrapped PassRefPtrs in move where passed to RefPtr constructor. (Closed)
Patch Set: Added move wraps for multiple instances in 1 line. Created 3 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/serviceworkers/ExtendableMessageEvent.h" 5 #include "modules/serviceworkers/ExtendableMessageEvent.h"
6 6
7 namespace blink { 7 namespace blink {
8 8
9 ExtendableMessageEvent* ExtendableMessageEvent::create( 9 ExtendableMessageEvent* ExtendableMessageEvent::create(
10 const AtomicString& type, 10 const AtomicString& type,
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 } 122 }
123 123
124 ExtendableMessageEvent::ExtendableMessageEvent( 124 ExtendableMessageEvent::ExtendableMessageEvent(
125 PassRefPtr<SerializedScriptValue> data, 125 PassRefPtr<SerializedScriptValue> data,
126 const String& origin, 126 const String& origin,
127 MessagePortArray* ports, 127 MessagePortArray* ports,
128 WaitUntilObserver* observer) 128 WaitUntilObserver* observer)
129 : ExtendableEvent(EventTypeNames::message, 129 : ExtendableEvent(EventTypeNames::message,
130 ExtendableMessageEventInit(), 130 ExtendableMessageEventInit(),
131 observer), 131 observer),
132 m_serializedData(data), 132 m_serializedData(std::move(data)),
133 m_origin(origin), 133 m_origin(origin),
134 m_lastEventId(String()), 134 m_lastEventId(String()),
135 m_ports(ports) { 135 m_ports(ports) {
136 if (m_serializedData) 136 if (m_serializedData)
137 m_serializedData->registerMemoryAllocatedWithCurrentScriptContext(); 137 m_serializedData->registerMemoryAllocatedWithCurrentScriptContext();
138 } 138 }
139 139
140 } // namespace blink 140 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698