OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/edit_search_engine_dialog.h" | 5 #include "chrome/browser/ui/views/edit_search_engine_dialog.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "base/i18n/rtl.h" | 8 #include "base/i18n/rtl.h" |
9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 keyword_iv_ = new ImageView(); | 140 keyword_iv_ = new ImageView(); |
141 url_iv_ = new ImageView(); | 141 url_iv_ = new ImageView(); |
142 | 142 |
143 UpdateImageViews(); | 143 UpdateImageViews(); |
144 | 144 |
145 const int related_x = kRelatedControlHorizontalSpacing; | 145 const int related_x = kRelatedControlHorizontalSpacing; |
146 const int related_y = kRelatedControlVerticalSpacing; | 146 const int related_y = kRelatedControlVerticalSpacing; |
147 const int unrelated_y = kUnrelatedControlVerticalSpacing; | 147 const int unrelated_y = kUnrelatedControlVerticalSpacing; |
148 | 148 |
149 // View and GridLayout take care of deleting GridLayout for us. | 149 // View and GridLayout take care of deleting GridLayout for us. |
150 GridLayout* layout = CreatePanelGridLayout(this); | 150 GridLayout* layout = GridLayout::CreatePanel(this); |
151 SetLayoutManager(layout); | 151 SetLayoutManager(layout); |
152 | 152 |
153 // Define the structure of the layout. | 153 // Define the structure of the layout. |
154 | 154 |
155 // For the buttons. | 155 // For the buttons. |
156 views::ColumnSet* column_set = layout->AddColumnSet(0); | 156 views::ColumnSet* column_set = layout->AddColumnSet(0); |
157 column_set->AddPaddingColumn(1, 0); | 157 column_set->AddPaddingColumn(1, 0); |
158 column_set->AddColumn(GridLayout::FILL, GridLayout::CENTER, 0, | 158 column_set->AddColumn(GridLayout::FILL, GridLayout::CENTER, 0, |
159 GridLayout::USE_PREF, 0, 0); | 159 GridLayout::USE_PREF, 0, 0); |
160 column_set->AddPaddingColumn(0, related_x); | 160 column_set->AddPaddingColumn(0, related_x); |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 ResourceBundle::GetSharedInstance().GetBitmapNamed( | 259 ResourceBundle::GetSharedInstance().GetBitmapNamed( |
260 IDR_INPUT_GOOD)); | 260 IDR_INPUT_GOOD)); |
261 } else { | 261 } else { |
262 image_view->SetTooltipText( | 262 image_view->SetTooltipText( |
263 UTF16ToWide(l10n_util::GetStringUTF16(invalid_message_id))); | 263 UTF16ToWide(l10n_util::GetStringUTF16(invalid_message_id))); |
264 image_view->SetImage( | 264 image_view->SetImage( |
265 ResourceBundle::GetSharedInstance().GetBitmapNamed( | 265 ResourceBundle::GetSharedInstance().GetBitmapNamed( |
266 IDR_INPUT_ALERT)); | 266 IDR_INPUT_ALERT)); |
267 } | 267 } |
268 } | 268 } |
OLD | NEW |