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

Unified Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 10837044: Correct const accessors in base/values.(h|cc), Part II (ListValue) (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 5 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/automation/testing_automation_provider.cc
diff --git a/chrome/browser/automation/testing_automation_provider.cc b/chrome/browser/automation/testing_automation_provider.cc
index 85cf92b829ddc39d5332bf2c1f58970fd730c137..387c9d24ea70602df689d31e111caf292ffd9b53 100644
--- a/chrome/browser/automation/testing_automation_provider.cc
+++ b/chrome/browser/automation/testing_automation_provider.cc
@@ -5111,8 +5111,8 @@ std::vector<AutofillProfile>
TestingAutomationProvider::GetAutofillProfilesFromList(
const ListValue& profiles, std::string* error_message) {
std::vector<AutofillProfile> autofill_profiles;
- DictionaryValue* profile_info = NULL;
- ListValue* current_value = NULL;
+ const DictionaryValue* profile_info = NULL;
+ const ListValue* current_value = NULL;
std::map<AutofillFieldType, std::string> autofill_type_to_string =
GetAutofillFieldToStringMap();
@@ -5128,7 +5128,7 @@ TestingAutomationProvider::GetAutofillProfilesFromList(
if (profile_info->HasKey(type_it->second)) {
if (profile_info->GetList(type_it->second, &current_value)) {
std::vector<string16> value_list;
- for (ListValue::iterator list_it = current_value->begin();
+ for (ListValue::const_iterator list_it = current_value->begin();
list_it != current_value->end(); ++list_it) {
string16 value;
if ((*list_it)->GetAsString(&value)) {
@@ -5154,7 +5154,7 @@ TestingAutomationProvider::GetAutofillProfilesFromList(
std::vector<CreditCard> TestingAutomationProvider::GetCreditCardsFromList(
const ListValue& cards, std::string* error_message) {
std::vector<CreditCard> credit_cards;
- DictionaryValue* card_info = NULL;
+ const DictionaryValue* card_info = NULL;
string16 current_value;
std::map<AutofillFieldType, std::string> credit_card_type_to_string =

Powered by Google App Engine
This is Rietveld 408576698