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/ui/views/crypto_module_password_dialog_view.h" | 5 #include "chrome/browser/ui/views/crypto_module_password_dialog_view.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "googleurl/src/gurl.h" | 10 #include "googleurl/src/gurl.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 break; | 68 break; |
69 default: | 69 default: |
70 NOTREACHED(); | 70 NOTREACHED(); |
71 } | 71 } |
72 reason_label_ = new views::Label(UTF8ToUTF16(text)); | 72 reason_label_ = new views::Label(UTF8ToUTF16(text)); |
73 reason_label_->SetMultiLine(true); | 73 reason_label_->SetMultiLine(true); |
74 | 74 |
75 password_label_ = new views::Label(l10n_util::GetStringUTF16( | 75 password_label_ = new views::Label(l10n_util::GetStringUTF16( |
76 IDS_CRYPTO_MODULE_AUTH_DIALOG_PASSWORD_FIELD)); | 76 IDS_CRYPTO_MODULE_AUTH_DIALOG_PASSWORD_FIELD)); |
77 | 77 |
78 password_entry_ = new views::Textfield(views::Textfield::STYLE_PASSWORD); | 78 password_entry_ = new views::Textfield(views::Textfield::STYLE_OBSCURED); |
79 password_entry_->SetController(this); | 79 password_entry_->SetController(this); |
80 | 80 |
81 views::GridLayout* layout = views::GridLayout::CreatePanel(this); | 81 views::GridLayout* layout = views::GridLayout::CreatePanel(this); |
82 SetLayoutManager(layout); | 82 SetLayoutManager(layout); |
83 | 83 |
84 views::ColumnSet* reason_column_set = layout->AddColumnSet(0); | 84 views::ColumnSet* reason_column_set = layout->AddColumnSet(0); |
85 reason_column_set->AddColumn( | 85 reason_column_set->AddColumn( |
86 views::GridLayout::LEADING, views::GridLayout::LEADING, 1, | 86 views::GridLayout::LEADING, views::GridLayout::LEADING, 1, |
87 views::GridLayout::USE_PREF, 0, 0); | 87 views::GridLayout::USE_PREF, 0, 0); |
88 | 88 |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 void CryptoModulePasswordDialogView::ContentsChanged( | 148 void CryptoModulePasswordDialogView::ContentsChanged( |
149 views::Textfield* sender, | 149 views::Textfield* sender, |
150 const string16& new_contents) { | 150 const string16& new_contents) { |
151 } | 151 } |
152 | 152 |
153 string16 CryptoModulePasswordDialogView::GetWindowTitle() const { | 153 string16 CryptoModulePasswordDialogView::GetWindowTitle() const { |
154 return UTF8ToUTF16(l10n_util::GetStringUTF8( | 154 return UTF8ToUTF16(l10n_util::GetStringUTF8( |
155 IDS_CRYPTO_MODULE_AUTH_DIALOG_TITLE)); | 155 IDS_CRYPTO_MODULE_AUTH_DIALOG_TITLE)); |
156 } | 156 } |
157 } // namespace browser | 157 } // namespace browser |
OLD | NEW |