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

Side by Side Diff: components/autofill/core/browser/autofill_profile.cc

Issue 23432002: Generate passwords only for forms that autofill server marks as account creation forms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address llya's nits and fix a bug in form structure unit test. Created 7 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/autofill/core/browser/autofill_profile.h" 5 #include "components/autofill/core/browser/autofill_profile.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 #include <map> 9 #include <map>
10 #include <ostream> 10 #include <ostream>
(...skipping 844 matching lines...) Expand 10 before | Expand all | Expand 10 after
855 case PHONE_HOME: 855 case PHONE_HOME:
856 case PHONE_BILLING: 856 case PHONE_BILLING:
857 return &phone_number_[0]; 857 return &phone_number_[0];
858 858
859 case ADDRESS_HOME: 859 case ADDRESS_HOME:
860 case ADDRESS_BILLING: 860 case ADDRESS_BILLING:
861 return &address_; 861 return &address_;
862 862
863 case NO_GROUP: 863 case NO_GROUP:
864 case CREDIT_CARD: 864 case CREDIT_CARD:
865 case PASSWORD_FIELD:
865 return NULL; 866 return NULL;
866 } 867 }
867 868
868 NOTREACHED(); 869 NOTREACHED();
869 return NULL; 870 return NULL;
870 } 871 }
871 872
872 // So we can compare AutofillProfiles with EXPECT_EQ(). 873 // So we can compare AutofillProfiles with EXPECT_EQ().
873 std::ostream& operator<<(std::ostream& os, const AutofillProfile& profile) { 874 std::ostream& operator<<(std::ostream& os, const AutofillProfile& profile) {
874 return os 875 return os
(...skipping 22 matching lines...) Expand all
897 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_STATE)) 898 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_STATE))
898 << " " 899 << " "
899 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_ZIP)) 900 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_ZIP))
900 << " " 901 << " "
901 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_COUNTRY)) 902 << UTF16ToUTF8(profile.GetRawInfo(ADDRESS_HOME_COUNTRY))
902 << " " 903 << " "
903 << UTF16ToUTF8(MultiString(profile, PHONE_HOME_WHOLE_NUMBER)); 904 << UTF16ToUTF8(MultiString(profile, PHONE_HOME_WHOLE_NUMBER));
904 } 905 }
905 906
906 } // namespace autofill 907 } // namespace autofill
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698