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 "views/controls/message_box_view.h" | 5 #include "views/controls/message_box_view.h" |
6 | 6 |
7 #include "base/i18n/rtl.h" | 7 #include "base/i18n/rtl.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "ui/base/clipboard/clipboard.h" | 10 #include "ui/base/clipboard/clipboard.h" |
11 #include "ui/base/clipboard/scoped_clipboard_writer.h" | 11 #include "ui/base/clipboard/scoped_clipboard_writer.h" |
12 #include "ui/base/message_box_flags.h" | 12 #include "ui/base/message_box_flags.h" |
13 #include "views/controls/button/checkbox.h" | 13 #include "views/controls/button/checkbox.h" |
14 #include "views/standard_layout.h" | 14 #include "views/grid_layout.h" |
| 15 #include "views/layout/layout_constants.h" |
15 #include "views/views_delegate.h" | 16 #include "views/views_delegate.h" |
16 #include "views/window/client_view.h" | 17 #include "views/window/client_view.h" |
17 | 18 |
18 static const int kDefaultMessageWidth = 320; | 19 static const int kDefaultMessageWidth = 320; |
19 | 20 |
20 /////////////////////////////////////////////////////////////////////////////// | 21 /////////////////////////////////////////////////////////////////////////////// |
21 // MessageBoxView, public: | 22 // MessageBoxView, public: |
22 | 23 |
23 MessageBoxView::MessageBoxView(int dialog_flags, | 24 MessageBoxView::MessageBoxView(int dialog_flags, |
24 const std::wstring& message, | 25 const std::wstring& message, |
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 } | 208 } |
208 | 209 |
209 if (checkbox_) { | 210 if (checkbox_) { |
210 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); | 211 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); |
211 layout->StartRow(0, checkbox_column_view_set_id); | 212 layout->StartRow(0, checkbox_column_view_set_id); |
212 layout->AddView(checkbox_); | 213 layout->AddView(checkbox_); |
213 } | 214 } |
214 | 215 |
215 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); | 216 layout->AddPaddingRow(0, kRelatedControlVerticalSpacing); |
216 } | 217 } |
OLD | NEW |