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

Unified Diff: chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc

Issue 2842833003: Update SupportsUserData uses with unique_ptr. (Closed)
Patch Set: rebase Created 3 years, 8 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: chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc
diff --git a/chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc b/chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc
index 6b964e12ae1d043dcd6a8ed617a1a67ba80b7158..cbaf4b49c6314c342d00fec651640ee869a5a2e4 100644
--- a/chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc
+++ b/chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/media/router/receiver_presentation_service_delegate_impl.h"
+#include "base/memory/ptr_util.h"
#include "chrome/browser/media/router/offscreen_presentation_manager.h"
#include "chrome/browser/media/router/offscreen_presentation_manager_factory.h"
@@ -23,9 +24,10 @@ void ReceiverPresentationServiceDelegateImpl::CreateForWebContents(
if (FromWebContents(web_contents))
return;
- web_contents->SetUserData(UserDataKey(),
- new ReceiverPresentationServiceDelegateImpl(
- web_contents, presentation_id));
+ web_contents->SetUserData(
+ UserDataKey(),
+ base::WrapUnique(new ReceiverPresentationServiceDelegateImpl(
+ web_contents, presentation_id)));
}
void ReceiverPresentationServiceDelegateImpl::AddObserver(

Powered by Google App Engine
This is Rietveld 408576698