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

Unified Diff: content/browser/presentation/presentation_service_impl.cc

Issue 2574673002: Removes ScopedVector from presentation_service_impl. (Closed)
Patch Set: Fixes test. Created 4 years 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: content/browser/presentation/presentation_service_impl.cc
diff --git a/content/browser/presentation/presentation_service_impl.cc b/content/browser/presentation/presentation_service_impl.cc
index b63de054061f9d9e733299d2ce850693ec815e17..7320b39fd4c828ddd8155d6411f028545b34803f 100644
--- a/content/browser/presentation/presentation_service_impl.cc
+++ b/content/browser/presentation/presentation_service_impl.cc
@@ -455,17 +455,19 @@ void PresentationServiceImpl::ListenForConnectionMessages(
void PresentationServiceImpl::OnConnectionMessages(
const PresentationSessionInfo& session,
- const ScopedVector<PresentationConnectionMessage>& messages,
+ const std::vector<std::unique_ptr<PresentationConnectionMessage>>& messages,
bool pass_ownership) {
DCHECK(client_);
DVLOG(2) << "OnConnectionMessages";
std::vector<blink::mojom::ConnectionMessagePtr> mojo_messages(
messages.size());
- std::transform(messages.begin(), messages.end(), mojo_messages.begin(),
- [pass_ownership](PresentationConnectionMessage* message) {
- return ToMojoConnectionMessage(message, pass_ownership);
- });
+ std::transform(
+ messages.begin(), messages.end(), mojo_messages.begin(),
+ [pass_ownership](
+ const std::unique_ptr<PresentationConnectionMessage>& message) {
+ return ToMojoConnectionMessage(message.get(), pass_ownership);
+ });
client_->OnConnectionMessagesReceived(
blink::mojom::PresentationSessionInfo::From(session),

Powered by Google App Engine
This is Rietveld 408576698