diff options
Diffstat (limited to 'components/autofill/content/browser')
8 files changed, 32 insertions, 31 deletions
diff --git a/components/autofill/content/browser/wallet/full_wallet.cc b/components/autofill/content/browser/wallet/full_wallet.cc index f66b28a..4a13b4f 100644 --- a/components/autofill/content/browser/wallet/full_wallet.cc +++ b/components/autofill/content/browser/wallet/full_wallet.cc @@ -44,8 +44,8 @@ FullWallet::~FullWallet() {} // static scoped_ptr<FullWallet> - FullWallet::CreateFullWallet(const DictionaryValue& dictionary) { - const ListValue* required_actions_list; + FullWallet::CreateFullWallet(const base::DictionaryValue& dictionary) { + const base::ListValue* required_actions_list; std::vector<RequiredAction> required_actions; if (dictionary.GetList("required_action", &required_actions_list)) { for (size_t i = 0; i < required_actions_list->GetSize(); ++i) { @@ -97,7 +97,7 @@ scoped_ptr<FullWallet> return scoped_ptr<FullWallet>(); } - const DictionaryValue* billing_address_dict; + const base::DictionaryValue* billing_address_dict; if (!dictionary.GetDictionary("billing_address", &billing_address_dict)) { DLOG(ERROR) << "Response from Google wallet missing billing address"; return scoped_ptr<FullWallet>(); @@ -110,7 +110,7 @@ scoped_ptr<FullWallet> return scoped_ptr<FullWallet>(); } - const DictionaryValue* shipping_address_dict; + const base::DictionaryValue* shipping_address_dict; scoped_ptr<Address> shipping_address; if (dictionary.GetDictionary("shipping_address", &shipping_address_dict)) { shipping_address = diff --git a/components/autofill/content/browser/wallet/full_wallet_unittest.cc b/components/autofill/content/browser/wallet/full_wallet_unittest.cc index 6f66213..59e6dd9 100644 --- a/components/autofill/content/browser/wallet/full_wallet_unittest.cc +++ b/components/autofill/content/browser/wallet/full_wallet_unittest.cc @@ -355,12 +355,12 @@ class FullWalletTest : public testing::Test { FullWalletTest() {} protected: void SetUpDictionary(const std::string& json) { - scoped_ptr<Value> value(base::JSONReader::Read(json)); + scoped_ptr<base::Value> value(base::JSONReader::Read(json)); ASSERT_TRUE(value.get()); - ASSERT_TRUE(value->IsType(Value::TYPE_DICTIONARY)); - dict.reset(static_cast<DictionaryValue*>(value.release())); + ASSERT_TRUE(value->IsType(base::Value::TYPE_DICTIONARY)); + dict.reset(static_cast<base::DictionaryValue*>(value.release())); } - scoped_ptr<DictionaryValue> dict; + scoped_ptr<base::DictionaryValue> dict; }; TEST_F(FullWalletTest, CreateFullWalletMissingExpirationMonth) { diff --git a/components/autofill/content/browser/wallet/wallet_address.cc b/components/autofill/content/browser/wallet/wallet_address.cc index e7ab050..6d41222 100644 --- a/components/autofill/content/browser/wallet/wallet_address.cc +++ b/components/autofill/content/browser/wallet/wallet_address.cc @@ -51,7 +51,7 @@ Address* CreateAddressInternal(const base::DictionaryValue& dictionary, base::string16 address_line_1; base::string16 address_line_2; - const ListValue* address_line_list; + const base::ListValue* address_line_list; if (dictionary.GetList("postal_address.address_line", &address_line_list)) { if (!address_line_list->GetString(0, &address_line_1)) DVLOG(1) << "Response from Google Wallet missing address line 1"; diff --git a/components/autofill/content/browser/wallet/wallet_address_unittest.cc b/components/autofill/content/browser/wallet/wallet_address_unittest.cc index 728d635..3fc1882 100644 --- a/components/autofill/content/browser/wallet/wallet_address_unittest.cc +++ b/components/autofill/content/browser/wallet/wallet_address_unittest.cc @@ -162,12 +162,12 @@ class WalletAddressTest : public testing::Test { WalletAddressTest() {} protected: void SetUpDictionary(const std::string& json) { - scoped_ptr<Value> value(base::JSONReader::Read(json)); + scoped_ptr<base::Value> value(base::JSONReader::Read(json)); DCHECK(value.get()); - DCHECK(value->IsType(Value::TYPE_DICTIONARY)); - dict_.reset(static_cast<DictionaryValue*>(value.release())); + DCHECK(value->IsType(base::Value::TYPE_DICTIONARY)); + dict_.reset(static_cast<base::DictionaryValue*>(value.release())); } - scoped_ptr<const DictionaryValue> dict_; + scoped_ptr<const base::DictionaryValue> dict_; }; TEST_F(WalletAddressTest, AddressEqualsIgnoreID) { diff --git a/components/autofill/content/browser/wallet/wallet_client.cc b/components/autofill/content/browser/wallet/wallet_client.cc index 9e4f5f2..c5475cd 100644 --- a/components/autofill/content/browser/wallet/wallet_client.cc +++ b/components/autofill/content/browser/wallet/wallet_client.cc @@ -590,9 +590,9 @@ void WalletClient::OnURLFetchComplete( // error code and message for the user. case net::HTTP_OK: case net::HTTP_INTERNAL_SERVER_ERROR: { - scoped_ptr<Value> message_value(base::JSONReader::Read(data)); + scoped_ptr<base::Value> message_value(base::JSONReader::Read(data)); if (message_value.get() && - message_value->IsType(Value::TYPE_DICTIONARY)) { + message_value->IsType(base::Value::TYPE_DICTIONARY)) { response_dict.reset( static_cast<base::DictionaryValue*>(message_value.release())); } diff --git a/components/autofill/content/browser/wallet/wallet_client_unittest.cc b/components/autofill/content/browser/wallet/wallet_client_unittest.cc index 2d3aac4..1ea7f03 100644 --- a/components/autofill/content/browser/wallet/wallet_client_unittest.cc +++ b/components/autofill/content/browser/wallet/wallet_client_unittest.cc @@ -842,14 +842,15 @@ class WalletClientTest : public testing::Test { private: std::string GetData(const std::string& upload_data) { - scoped_ptr<Value> root(base::JSONReader::Read(upload_data)); + scoped_ptr<base::Value> root(base::JSONReader::Read(upload_data)); // If this is not a JSON dictionary, return plain text. - if (!root || !root->IsType(Value::TYPE_DICTIONARY)) + if (!root || !root->IsType(base::Value::TYPE_DICTIONARY)) return upload_data; // Remove api_key entry (to prevent accidental leak), return JSON as text. - DictionaryValue* dict = static_cast<DictionaryValue*>(root.get()); + base::DictionaryValue* dict = + static_cast<base::DictionaryValue*>(root.get()); dict->Remove("api_key", NULL); std::string clean_upload_data; base::JSONWriter::Write(dict, &clean_upload_data); diff --git a/components/autofill/content/browser/wallet/wallet_items.cc b/components/autofill/content/browser/wallet/wallet_items.cc index f947266..f655882 100644 --- a/components/autofill/content/browser/wallet/wallet_items.cc +++ b/components/autofill/content/browser/wallet/wallet_items.cc @@ -155,7 +155,7 @@ scoped_ptr<WalletItems::MaskedInstrument> return scoped_ptr<MaskedInstrument>(); } - const DictionaryValue* address_dict; + const base::DictionaryValue* address_dict; if (!dictionary.GetDictionary("billing_address", &address_dict)) { DLOG(ERROR) << "Response from Google wallet missing address"; return scoped_ptr<MaskedInstrument>(); @@ -168,7 +168,7 @@ scoped_ptr<WalletItems::MaskedInstrument> } std::vector<base::string16> supported_currencies; - const ListValue* supported_currency_list; + const base::ListValue* supported_currency_list; if (dictionary.GetList("supported_currency", &supported_currency_list)) { for (size_t i = 0; i < supported_currency_list->GetSize(); ++i) { base::string16 currency; @@ -437,7 +437,7 @@ WalletItems::~WalletItems() {} scoped_ptr<WalletItems> WalletItems::CreateWalletItems(const base::DictionaryValue& dictionary) { std::vector<RequiredAction> required_action; - const ListValue* required_action_list; + const base::ListValue* required_action_list; if (dictionary.GetList("required_action", &required_action_list)) { for (size_t i = 0; i < required_action_list->GetSize(); ++i) { std::string action_string; @@ -501,10 +501,10 @@ scoped_ptr<WalletItems> DVLOG(1) << "Response from Google wallet missing GAIA accounts"; } - const ListValue* legal_docs; + const base::ListValue* legal_docs; if (dictionary.GetList("required_legal_document", &legal_docs)) { for (size_t i = 0; i < legal_docs->GetSize(); ++i) { - const DictionaryValue* legal_doc_dict; + const base::DictionaryValue* legal_doc_dict; if (legal_docs->GetDictionary(i, &legal_doc_dict)) { scoped_ptr<LegalDocument> legal_doc( LegalDocument::CreateLegalDocument(*legal_doc_dict)); @@ -524,10 +524,10 @@ scoped_ptr<WalletItems> DVLOG(1) << "Response from Google wallet missing legal docs"; } - const ListValue* instruments; + const base::ListValue* instruments; if (dictionary.GetList("instrument", &instruments)) { for (size_t i = 0; i < instruments->GetSize(); ++i) { - const DictionaryValue* instrument_dict; + const base::DictionaryValue* instrument_dict; if (instruments->GetDictionary(i, &instrument_dict)) { scoped_ptr<MaskedInstrument> instrument( MaskedInstrument::CreateMaskedInstrument(*instrument_dict)); @@ -539,10 +539,10 @@ scoped_ptr<WalletItems> DVLOG(1) << "Response from Google wallet missing instruments"; } - const ListValue* addresses; + const base::ListValue* addresses; if (dictionary.GetList("address", &addresses)) { for (size_t i = 0; i < addresses->GetSize(); ++i) { - const DictionaryValue* address_dict; + const base::DictionaryValue* address_dict; if (addresses->GetDictionary(i, &address_dict)) { scoped_ptr<Address> address( Address::CreateAddressWithID(*address_dict)); diff --git a/components/autofill/content/browser/wallet/wallet_items_unittest.cc b/components/autofill/content/browser/wallet/wallet_items_unittest.cc index 02217be..f0f299b 100644 --- a/components/autofill/content/browser/wallet/wallet_items_unittest.cc +++ b/components/autofill/content/browser/wallet/wallet_items_unittest.cc @@ -393,12 +393,12 @@ class WalletItemsTest : public testing::Test { WalletItemsTest() {} protected: void SetUpDictionary(const std::string& json) { - scoped_ptr<Value> value(base::JSONReader::Read(json)); + scoped_ptr<base::Value> value(base::JSONReader::Read(json)); ASSERT_TRUE(value.get()); - ASSERT_TRUE(value->IsType(Value::TYPE_DICTIONARY)); - dict.reset(static_cast<DictionaryValue*>(value.release())); + ASSERT_TRUE(value->IsType(base::Value::TYPE_DICTIONARY)); + dict.reset(static_cast<base::DictionaryValue*>(value.release())); } - scoped_ptr<DictionaryValue> dict; + scoped_ptr<base::DictionaryValue> dict; }; TEST_F(WalletItemsTest, CreateMaskedInstrumentMissingStatus) { |