| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/chromeos/login/password_changed_view.h" | 5 #include "chrome/browser/chromeos/login/password_changed_view.h" |
| 6 | 6 |
| 7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
| 8 #include "chrome/browser/chromeos/login/rounded_rect_painter.h" | 8 #include "chrome/browser/chromeos/login/rounded_rect_painter.h" |
| 9 #include "chrome/browser/chromeos/login/textfield_with_margin.h" | 9 #include "chrome/browser/chromeos/login/textfield_with_margin.h" |
| 10 #include "grit/generated_resources.h" | 10 #include "grit/generated_resources.h" |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 l10n_util::GetStringUTF16(IDS_LOGIN_PASSWORD_CHANGED_RESET), 0); | 107 l10n_util::GetStringUTF16(IDS_LOGIN_PASSWORD_CHANGED_RESET), 0); |
| 108 full_sync_radio_->set_listener(this); | 108 full_sync_radio_->set_listener(this); |
| 109 full_sync_radio_->SetMultiLine(true); | 109 full_sync_radio_->SetMultiLine(true); |
| 110 | 110 |
| 111 delta_sync_radio_ = new RadioButton( | 111 delta_sync_radio_ = new RadioButton( |
| 112 l10n_util::GetStringUTF16(IDS_LOGIN_PASSWORD_CHANGED_MIGRATE), 0); | 112 l10n_util::GetStringUTF16(IDS_LOGIN_PASSWORD_CHANGED_MIGRATE), 0); |
| 113 delta_sync_radio_->set_listener(this); | 113 delta_sync_radio_->set_listener(this); |
| 114 delta_sync_radio_->SetMultiLine(true); | 114 delta_sync_radio_->SetMultiLine(true); |
| 115 | 115 |
| 116 old_password_field_ = new TextfieldWithMargin(Textfield::STYLE_OBSCURED); | 116 old_password_field_ = new TextfieldWithMargin(Textfield::STYLE_OBSCURED); |
| 117 old_password_field_->set_text_to_display_when_empty( | 117 old_password_field_->set_placeholder_text( |
| 118 l10n_util::GetStringUTF16(IDS_LOGIN_PREVIOUS_PASSWORD)); | 118 l10n_util::GetStringUTF16(IDS_LOGIN_PREVIOUS_PASSWORD)); |
| 119 old_password_field_->set_default_width_in_chars(kPasswordFieldWidthChars); | 119 old_password_field_->set_default_width_in_chars(kPasswordFieldWidthChars); |
| 120 old_password_field_->SetController(this); | 120 old_password_field_->SetController(this); |
| 121 | 121 |
| 122 // Define controls layout. | 122 // Define controls layout. |
| 123 GridLayout* layout = GridLayout::CreatePanel(this); | 123 GridLayout* layout = GridLayout::CreatePanel(this); |
| 124 SetLayoutManager(layout); | 124 SetLayoutManager(layout); |
| 125 | 125 |
| 126 views::ColumnSet* column_set = layout->AddColumnSet(0); | 126 views::ColumnSet* column_set = layout->AddColumnSet(0); |
| 127 column_set->AddColumn(GridLayout::LEADING, GridLayout::FILL, 1, | 127 column_set->AddColumn(GridLayout::LEADING, GridLayout::FILL, 1, |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 old_password_field_->RequestFocus(); | 182 old_password_field_->RequestFocus(); |
| 183 } | 183 } |
| 184 } | 184 } |
| 185 | 185 |
| 186 bool PasswordChangedView::HandleKeyEvent(views::Textfield* sender, | 186 bool PasswordChangedView::HandleKeyEvent(views::Textfield* sender, |
| 187 const views::KeyEvent& keystroke) { | 187 const views::KeyEvent& keystroke) { |
| 188 return false; | 188 return false; |
| 189 } | 189 } |
| 190 | 190 |
| 191 } // namespace chromeos | 191 } // namespace chromeos |
| OLD | NEW |