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: chromecast/browser/android/cast_web_contents_activity.cc

Issue 2844413004: Switch SupportsUserData uses to use unique_ptr. (Closed)
Patch Set: 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
« no previous file with comments | « chromecast/browser/android/cast_web_contents_activity.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromecast/browser/android/cast_web_contents_activity.cc
diff --git a/chromecast/browser/android/cast_web_contents_activity.cc b/chromecast/browser/android/cast_web_contents_activity.cc
index f62fc05c26c5bcf134ed9e92a8167869afb4e842..8f314e598f8c11445badb41168027a2bd65d3782 100644
--- a/chromecast/browser/android/cast_web_contents_activity.cc
+++ b/chromecast/browser/android/cast_web_contents_activity.cc
@@ -4,6 +4,7 @@
#include "chromecast/browser/android/cast_web_contents_activity.h"
+#include "base/memory/ptr_util.h"
#include "content/public/browser/web_contents.h"
#include "jni/CastWebContentsActivity_jni.h"
@@ -46,7 +47,8 @@ CastWebContentsActivity* CastWebContentsActivity::Get(
web_contents->GetUserData(kCastWebContentsActivityKey));
if (!instance) {
instance = new CastWebContentsActivity(web_contents);
- web_contents->SetUserData(kCastWebContentsActivityKey, instance);
+ web_contents->SetUserData(kCastWebContentsActivityKey,
+ base::WrapUnique(instance));
}
return instance;
}
« no previous file with comments | « chromecast/browser/android/cast_web_contents_activity.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698