OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chrome/browser/ui/views/autofill/view_util.h" |
| 6 |
| 7 #include "components/strings/grit/components_strings.h" |
| 8 #include "ui/base/l10n/l10n_util.h" |
| 9 #include "ui/views/controls/textfield/textfield.h" |
| 10 |
| 11 namespace autofill { |
| 12 |
| 13 views::Textfield* CreateCvcTextfield() { |
| 14 views::Textfield* textfield = new views::Textfield(); |
| 15 textfield->set_placeholder_text( |
| 16 l10n_util::GetStringUTF16(IDS_AUTOFILL_DIALOG_PLACEHOLDER_CVC)); |
| 17 textfield->set_default_width_in_chars(8); |
| 18 textfield->SetTextInputType(ui::TextInputType::TEXT_INPUT_TYPE_NUMBER); |
| 19 return textfield; |
| 20 } |
| 21 |
| 22 } // namespace autofill |
OLD | NEW |