OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/views/select_profile_dialog.h" | 5 #include "chrome/browser/views/select_profile_dialog.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 } | 64 } |
65 | 65 |
66 void SelectProfileDialog::Layout() { | 66 void SelectProfileDialog::Layout() { |
67 GetLayoutManager()->Layout(this); | 67 GetLayoutManager()->Layout(this); |
68 } | 68 } |
69 | 69 |
70 int SelectProfileDialog::GetDialogButtons() const { | 70 int SelectProfileDialog::GetDialogButtons() const { |
71 return DIALOGBUTTON_OK | DIALOGBUTTON_CANCEL; | 71 return DIALOGBUTTON_OK | DIALOGBUTTON_CANCEL; |
72 } | 72 } |
73 | 73 |
74 views::View* SelectProfileDialog::GetInitiallyFocusedView() const { | 74 views::View* SelectProfileDialog::GetInitiallyFocusedView() { |
75 return profile_combobox_; | 75 return profile_combobox_; |
76 } | 76 } |
77 | 77 |
78 std::wstring SelectProfileDialog::GetWindowTitle() const { | 78 std::wstring SelectProfileDialog::GetWindowTitle() const { |
79 return l10n_util::GetString(IDS_SELECT_PROFILE_DIALOG_TITLE); | 79 return l10n_util::GetString(IDS_SELECT_PROFILE_DIALOG_TITLE); |
80 } | 80 } |
81 | 81 |
82 bool SelectProfileDialog::Accept() { | 82 bool SelectProfileDialog::Accept() { |
83 int index = profile_combobox_->GetSelectedItem(); | 83 int index = profile_combobox_->GetSelectedItem(); |
84 if (index < 0) { | 84 if (index < 0) { |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 column_set->AddPaddingColumn(0, kRelatedControlHorizontalSpacing); | 144 column_set->AddPaddingColumn(0, kRelatedControlHorizontalSpacing); |
145 column_set->AddColumn(GridLayout::FILL, GridLayout::CENTER, 0, | 145 column_set->AddColumn(GridLayout::FILL, GridLayout::CENTER, 0, |
146 GridLayout::FIXED, 200, 0); | 146 GridLayout::FIXED, 200, 0); |
147 | 147 |
148 layout->StartRow(0, column_set_id); | 148 layout->StartRow(0, column_set_id); |
149 layout->AddView(select_profile_label_); | 149 layout->AddView(select_profile_label_); |
150 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); | 150 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); |
151 layout->StartRow(0, column_set_id); | 151 layout->StartRow(0, column_set_id); |
152 layout->AddView(profile_combobox_); | 152 layout->AddView(profile_combobox_); |
153 } | 153 } |
OLD | NEW |