| Index: chrome/browser/ui/views/payments/credit_card_editor_view_controller.cc
|
| diff --git a/chrome/browser/ui/views/payments/credit_card_editor_view_controller.cc b/chrome/browser/ui/views/payments/credit_card_editor_view_controller.cc
|
| index 09fa367985cc440e241a150383822593e2496e2b..ed385a0882ccde3dc3f2e921c4d0fb5eaf0fecb2 100644
|
| --- a/chrome/browser/ui/views/payments/credit_card_editor_view_controller.cc
|
| +++ b/chrome/browser/ui/views/payments/credit_card_editor_view_controller.cc
|
| @@ -335,6 +335,20 @@ CreditCardEditorViewController::GetComboboxModelForType(
|
| return std::unique_ptr<ui::ComboboxModel>();
|
| }
|
|
|
| +void CreditCardEditorViewController::FillContentView(
|
| + views::View* content_view) {
|
| + EditorViewController::FillContentView(content_view);
|
| + // We need to search from the content view here, since the dialog may not have
|
| + // the content view added to it yet.
|
| + views::Combobox* combobox = static_cast<views::Combobox*>(
|
| + content_view->GetViewByID(kBillingAddressType));
|
| + // When the combobox has a single item, it's because it has no addresses
|
| + // (otherwise, it would have the select header, and a separator before the
|
| + // first address to choose from).
|
| + DCHECK(combobox);
|
| + combobox->SetEnabled(combobox->GetRowCount() > 1);
|
| +}
|
| +
|
| base::string16 CreditCardEditorViewController::GetSheetTitle() {
|
| if (!credit_card_to_edit_)
|
| return l10n_util::GetStringUTF16(IDS_PAYMENTS_ADD_CARD);
|
|
|