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

Unified Diff: ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm

Issue 1861593005: Convert //ios from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase? Created 4 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: ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm
diff --git a/ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm b/ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm
index 17a2ef247bccdfbf053f80e98fa5864f9229d350..af12ac095382b7677c7dcb08f353ceeb482821a1 100644
--- a/ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm
+++ b/ios/chrome/browser/passwords/ios_chrome_save_password_infobar_delegate.mm
@@ -7,6 +7,7 @@
#include <utility>
#include "base/mac/scoped_nsobject.h"
+#include "base/memory/ptr_util.h"
#include "base/metrics/histogram.h"
#include "base/strings/string16.h"
#include "components/infobars/core/infobar.h"
@@ -30,9 +31,9 @@ using password_manager::PasswordFormManager;
void IOSChromeSavePasswordInfoBarDelegate::Create(
bool is_smart_lock_branding_enabled,
infobars::InfoBarManager* infobar_manager,
- scoped_ptr<PasswordFormManager> form_to_save) {
+ std::unique_ptr<PasswordFormManager> form_to_save) {
DCHECK(infobar_manager);
- auto delegate = make_scoped_ptr(new IOSChromeSavePasswordInfoBarDelegate(
+ auto delegate = base::WrapUnique(new IOSChromeSavePasswordInfoBarDelegate(
is_smart_lock_branding_enabled, std::move(form_to_save)));
infobar_manager->AddInfoBar(
infobar_manager->CreateConfirmInfoBar(std::move(delegate)));
@@ -44,7 +45,7 @@ IOSChromeSavePasswordInfoBarDelegate::~IOSChromeSavePasswordInfoBarDelegate() {
IOSChromeSavePasswordInfoBarDelegate::IOSChromeSavePasswordInfoBarDelegate(
bool is_smart_lock_branding_enabled,
- scoped_ptr<PasswordFormManager> form_to_save)
+ std::unique_ptr<PasswordFormManager> form_to_save)
: form_to_save_(std::move(form_to_save)),
infobar_response_(password_manager::metrics_util::NO_DIRECT_INTERACTION),
is_smart_lock_branding_enabled_(is_smart_lock_branding_enabled) {}

Powered by Google App Engine
This is Rietveld 408576698