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

Unified Diff: chrome/browser/ui/autofill/chrome_autofill_client.cc

Issue 1865213004: Convert //chrome/browser/ui 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: chrome/browser/ui/autofill/chrome_autofill_client.cc
diff --git a/chrome/browser/ui/autofill/chrome_autofill_client.cc b/chrome/browser/ui/autofill/chrome_autofill_client.cc
index 365ce5d2fc223be7f30d80cf51ff06b2d1a8b7ab..aed5945b87fe33b56e68993e5023962997e3dfa4 100644
--- a/chrome/browser/ui/autofill/chrome_autofill_client.cc
+++ b/chrome/browser/ui/autofill/chrome_autofill_client.cc
@@ -9,6 +9,7 @@
#include "base/bind.h"
#include "base/command_line.h"
#include "base/logging.h"
+#include "base/memory/ptr_util.h"
#include "build/build_config.h"
#include "chrome/browser/autofill/personal_data_manager_factory.h"
#include "chrome/browser/autofill/risk_util.h"
@@ -175,10 +176,10 @@ void ChromeAutofillClient::ConfirmSaveCreditCardLocally(
const CreditCard& card,
const base::Closure& callback) {
#if defined(OS_ANDROID)
- InfoBarService::FromWebContents(web_contents())->AddInfoBar(
- CreateSaveCardInfoBarMobile(
- make_scoped_ptr(new AutofillSaveCardInfoBarDelegateMobile(
- false, card, scoped_ptr<base::DictionaryValue>(nullptr),
+ InfoBarService::FromWebContents(web_contents())
+ ->AddInfoBar(CreateSaveCardInfoBarMobile(
+ base::WrapUnique(new AutofillSaveCardInfoBarDelegateMobile(
+ false, card, std::unique_ptr<base::DictionaryValue>(nullptr),
callback))));
#else
// Do lazy initialization of SaveCardBubbleControllerImpl.
@@ -192,12 +193,12 @@ void ChromeAutofillClient::ConfirmSaveCreditCardLocally(
void ChromeAutofillClient::ConfirmSaveCreditCardToCloud(
const CreditCard& card,
- scoped_ptr<base::DictionaryValue> legal_message,
+ std::unique_ptr<base::DictionaryValue> legal_message,
const base::Closure& callback) {
#if defined(OS_ANDROID)
- InfoBarService::FromWebContents(web_contents())->AddInfoBar(
- CreateSaveCardInfoBarMobile(
- make_scoped_ptr(new AutofillSaveCardInfoBarDelegateMobile(
+ InfoBarService::FromWebContents(web_contents())
+ ->AddInfoBar(CreateSaveCardInfoBarMobile(
+ base::WrapUnique(new AutofillSaveCardInfoBarDelegateMobile(
true, card, std::move(legal_message), callback))));
#else
// Do lazy initialization of SaveCardBubbleControllerImpl.
« no previous file with comments | « chrome/browser/ui/autofill/chrome_autofill_client.h ('k') | chrome/browser/ui/autofill/country_combobox_model_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698