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

Unified Diff: components/offline_items_collection/core/android/offline_content_aggregator_bridge.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: components/offline_items_collection/core/android/offline_content_aggregator_bridge.cc
diff --git a/components/offline_items_collection/core/android/offline_content_aggregator_bridge.cc b/components/offline_items_collection/core/android/offline_content_aggregator_bridge.cc
index 892a0b7fbaf631cc4d01273d07eb75c8bd0cf50d..eef6057d986a95b01425ab0aefde911ce3d211f0 100644
--- a/components/offline_items_collection/core/android/offline_content_aggregator_bridge.cc
+++ b/components/offline_items_collection/core/android/offline_content_aggregator_bridge.cc
@@ -55,8 +55,9 @@ base::android::ScopedJavaLocalRef<jobject>
OfflineContentAggregatorBridge::GetBridgeForOfflineContentAggregator(
OfflineContentAggregator* aggregator) {
if (!aggregator->GetUserData(kOfflineContentAggregatorBridgeUserDataKey)) {
- aggregator->SetUserData(kOfflineContentAggregatorBridgeUserDataKey,
- new OfflineContentAggregatorBridge(aggregator));
+ aggregator->SetUserData(
+ kOfflineContentAggregatorBridgeUserDataKey,
+ base::WrapUnique(new OfflineContentAggregatorBridge(aggregator)));
}
OfflineContentAggregatorBridge* bridge =
static_cast<OfflineContentAggregatorBridge*>(

Powered by Google App Engine
This is Rietveld 408576698