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

Unified Diff: chrome/browser/importer/external_process_importer_client.cc

Issue 2577563002: Add struct traits for base::Value. (Closed)
Patch Set: Created 4 years 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/importer/external_process_importer_client.cc
diff --git a/chrome/browser/importer/external_process_importer_client.cc b/chrome/browser/importer/external_process_importer_client.cc
index 2ad13d4b0281346f6edfb7c58986837571d87532..30061f0d4d5a678974ca6d79076f8c974cdd9eeb 100644
--- a/chrome/browser/importer/external_process_importer_client.cc
+++ b/chrome/browser/importer/external_process_importer_client.cc
@@ -56,31 +56,33 @@ void ExternalProcessImporterClient::Start() {
// Dictionary of all localized strings that could be needed by the importer
// in the external process.
- base::DictionaryValue localized_strings;
- localized_strings.SetString(base::IntToString(IDS_BOOKMARK_GROUP),
- l10n_util::GetStringUTF8(IDS_BOOKMARK_GROUP));
- localized_strings.SetString(
+ auto localized_strings = base::MakeUnique<base::DictionaryValue>();
+ localized_strings->SetString(base::IntToString(IDS_BOOKMARK_GROUP),
+ l10n_util::GetStringUTF8(IDS_BOOKMARK_GROUP));
+ localized_strings->SetString(
base::IntToString(IDS_BOOKMARK_GROUP_FROM_FIREFOX),
l10n_util::GetStringUTF8(IDS_BOOKMARK_GROUP_FROM_FIREFOX));
- localized_strings.SetString(
+ localized_strings->SetString(
base::IntToString(IDS_BOOKMARK_GROUP_FROM_SAFARI),
l10n_util::GetStringUTF8(IDS_BOOKMARK_GROUP_FROM_SAFARI));
- localized_strings.SetString(
+ localized_strings->SetString(
base::IntToString(IDS_IMPORT_FROM_FIREFOX),
l10n_util::GetStringUTF8(IDS_IMPORT_FROM_FIREFOX));
- localized_strings.SetString(
+ localized_strings->SetString(
base::IntToString(IDS_IMPORT_FROM_ICEWEASEL),
l10n_util::GetStringUTF8(IDS_IMPORT_FROM_ICEWEASEL));
- localized_strings.SetString(base::IntToString(IDS_IMPORT_FROM_SAFARI),
- l10n_util::GetStringUTF8(IDS_IMPORT_FROM_SAFARI));
- localized_strings.SetString(
+ localized_strings->SetString(
+ base::IntToString(IDS_IMPORT_FROM_SAFARI),
+ l10n_util::GetStringUTF8(IDS_IMPORT_FROM_SAFARI));
+ localized_strings->SetString(
base::IntToString(IDS_BOOKMARK_BAR_FOLDER_NAME),
l10n_util::GetStringUTF8(IDS_BOOKMARK_BAR_FOLDER_NAME));
// If the utility process hasn't started yet the message will queue until it
// does.
auto observer_ptr = binding_.CreateInterfacePtrAndBind();
- profile_import_->StartImport(source_profile_, items_, localized_strings,
+ profile_import_->StartImport(source_profile_, items_,
+ std::move(localized_strings),
std::move(observer_ptr));
}

Powered by Google App Engine
This is Rietveld 408576698