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 "chrome/browser/ui/autofill/account_chooser_model.h" | 5 #include "chrome/browser/ui/autofill/account_chooser_model.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/prefs/pref_service.h" | 8 #include "base/prefs/pref_service.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 Clear(); | 131 Clear(); |
132 const gfx::Image& wallet_icon = | 132 const gfx::Image& wallet_icon = |
133 ui::ResourceBundle::GetSharedInstance().GetImageNamed(IDR_WALLET_ICON); | 133 ui::ResourceBundle::GetSharedInstance().GetImageNamed(IDR_WALLET_ICON); |
134 | 134 |
135 if (!active_wallet_account_name_.empty()) { | 135 if (!active_wallet_account_name_.empty()) { |
136 AddCheckItem(kActiveWalletItemId, active_wallet_account_name_); | 136 AddCheckItem(kActiveWalletItemId, active_wallet_account_name_); |
137 SetIcon(GetIndexOfCommandId(kActiveWalletItemId), wallet_icon); | 137 SetIcon(GetIndexOfCommandId(kActiveWalletItemId), wallet_icon); |
138 } else if (checked_item_ == kActiveWalletItemId) { | 138 } else if (checked_item_ == kActiveWalletItemId) { |
139 // A selected active Wallet account with an empty account name means | 139 // A selected active Wallet account with an empty account name means |
140 // that the sign-in attempt is in progress. | 140 // that the sign-in attempt is in progress. |
141 // TODO(aruslan): http://crbug.com/230932 | |
142 // A throbber should be shown until the Wallet account name is set. | |
143 AddCheckItem(kActiveWalletItemId, | 141 AddCheckItem(kActiveWalletItemId, |
144 l10n_util::GetStringUTF16(IDS_AUTOFILL_DIALOG_GOOGLE_WALLET)); | 142 l10n_util::GetStringUTF16(IDS_AUTOFILL_DIALOG_GOOGLE_WALLET)); |
145 } | 143 } |
146 | 144 |
147 AddCheckItemWithStringId(kAutofillItemId, | 145 AddCheckItemWithStringId(kAutofillItemId, |
148 IDS_AUTOFILL_DIALOG_PAY_WITHOUT_WALLET); | 146 IDS_AUTOFILL_DIALOG_PAY_WITHOUT_WALLET); |
149 } | 147 } |
150 | 148 |
151 } // namespace autofill | 149 } // namespace autofill |
OLD | NEW |