| OLD | NEW |
| 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/form_group.h" | 5 #include "components/autofill/core/browser/form_group.h" |
| 6 | 6 |
| 7 #include "components/autofill/core/browser/autofill_type.h" | 7 #include "components/autofill/core/browser/autofill_type.h" |
| 8 | 8 |
| 9 namespace autofill { | 9 namespace autofill { |
| 10 | 10 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 GetSupportedTypes(&types); | 31 GetSupportedTypes(&types); |
| 32 for (ServerFieldTypeSet::const_iterator type = types.begin(); | 32 for (ServerFieldTypeSet::const_iterator type = types.begin(); |
| 33 type != types.end(); ++type) { | 33 type != types.end(); ++type) { |
| 34 if (!GetInfo(AutofillType(*type), app_locale).empty()) | 34 if (!GetInfo(AutofillType(*type), app_locale).empty()) |
| 35 non_empty_types->insert(*type); | 35 non_empty_types->insert(*type); |
| 36 } | 36 } |
| 37 } | 37 } |
| 38 | 38 |
| 39 base::string16 FormGroup::GetInfo(const AutofillType& type, | 39 base::string16 FormGroup::GetInfo(const AutofillType& type, |
| 40 const std::string& app_locale) const { | 40 const std::string& app_locale) const { |
| 41 return GetRawInfo(type.server_type()); | 41 return GetRawInfo(type.GetStorableType()); |
| 42 } | 42 } |
| 43 | 43 |
| 44 bool FormGroup::SetInfo(const AutofillType& type, | 44 bool FormGroup::SetInfo(const AutofillType& type, |
| 45 const base::string16& value, | 45 const base::string16& value, |
| 46 const std::string& app_locale) { | 46 const std::string& app_locale) { |
| 47 SetRawInfo(type.server_type(), value); | 47 SetRawInfo(type.GetStorableType(), value); |
| 48 return true; | 48 return true; |
| 49 } | 49 } |
| 50 | 50 |
| 51 } // namespace autofill | 51 } // namespace autofill |
| OLD | NEW |