Chromium Code Reviews| Index: chrome/browser/ui/autofill/autofill_dialog_utils.h |
| diff --git a/chrome/browser/ui/autofill/autofill_dialog_utils.h b/chrome/browser/ui/autofill/autofill_dialog_utils.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..914f57925dd6194d5b303ebae32df0f52a9af0a3 |
| --- /dev/null |
| +++ b/chrome/browser/ui/autofill/autofill_dialog_utils.h |
| @@ -0,0 +1,40 @@ |
| +// Copyright 2013 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CHROME_BROWSER_UI_AUTOFILL_AUTOFILL_DIALOG_UTILS_H_ |
| +#define CHROME_BROWSER_UI_AUTOFILL_AUTOFILL_DIALOG_UTILS_H_ |
| + |
| +#include "chrome/browser/ui/autofill/autofill_dialog_types.h" |
| +#include "components/autofill/core/browser/field_types.h" |
| + |
| +namespace autofill { |
| +class AutofillProfile; |
| +} |
| + |
| +namespace wallet { |
| +class Address; |
| +} |
| + |
| +namespace autofill { |
| +namespace utils { |
|
Evan Stade
2013/08/01 19:44:52
I would call this common, not utils. These are mos
aruslan
2013/08/07 23:17:03
Done: renamed to common.
|
| + |
| +// Returns true if |input| should be shown when |field_type| has been requested. |
| +bool InputTypeMatchesFieldType(const DetailInput& input, |
| + AutofillFieldType field_type); |
| + |
| +// Returns true if |input| in the given |section| should be used for a |
| +// site-requested |field|. |
| +bool DetailInputMatchesField(DialogSection section, |
| + const DetailInput& input, |
| + const AutofillField& field); |
| + |
| +bool IsCreditCardType(AutofillFieldType type); |
| + |
| +// Constructs |inputs| from template data for a given |dialog_section|. |
| +void BuildInputsForSection(DialogSection dialog_section, DetailInputs* inputs); |
| + |
| +} // namespace utils |
| +} // namespace autofill |
| + |
| +#endif // CHROME_BROWSER_UI_AUTOFILL_AUTOFILL_DIALOG_UTILS_H_ |