| 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/restart_message_box.h" | 5 #include "chrome/browser/ui/views/restart_message_box.h" |
| 6 | 6 |
| 7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
| 8 #include "grit/chromium_strings.h" | 8 #include "grit/chromium_strings.h" |
| 9 #include "grit/generated_resources.h" | 9 #include "grit/generated_resources.h" |
| 10 #include "ui/base/l10n/l10n_util.h" | 10 #include "ui/base/l10n/l10n_util.h" |
| 11 #include "ui/base/message_box_flags.h" | 11 #include "ui/base/message_box_flags.h" |
| 12 #include "ui/views/widget/widget.h" | |
| 13 #include "views/controls/message_box_view.h" | 12 #include "views/controls/message_box_view.h" |
| 13 #include "views/widget/widget.h" |
| 14 | 14 |
| 15 //////////////////////////////////////////////////////////////////////////////// | 15 //////////////////////////////////////////////////////////////////////////////// |
| 16 // RestartMessageBox, public: | 16 // RestartMessageBox, public: |
| 17 | 17 |
| 18 // static | 18 // static |
| 19 void RestartMessageBox::ShowMessageBox(gfx::NativeWindow parent_window) { | 19 void RestartMessageBox::ShowMessageBox(gfx::NativeWindow parent_window) { |
| 20 // When the window closes, it will delete itself. | 20 // When the window closes, it will delete itself. |
| 21 new RestartMessageBox(parent_window); | 21 new RestartMessageBox(parent_window); |
| 22 } | 22 } |
| 23 | 23 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 ui::MessageBoxFlags::kFlagHasMessage | | 65 ui::MessageBoxFlags::kFlagHasMessage | |
| 66 ui::MessageBoxFlags::kFlagHasOKButton, | 66 ui::MessageBoxFlags::kFlagHasOKButton, |
| 67 l10n_util::GetStringUTF16(IDS_OPTIONS_RELAUNCH_REQUIRED), | 67 l10n_util::GetStringUTF16(IDS_OPTIONS_RELAUNCH_REQUIRED), |
| 68 string16(), | 68 string16(), |
| 69 kDialogWidth); | 69 kDialogWidth); |
| 70 views::Widget::CreateWindowWithParent(this, parent_window)->Show(); | 70 views::Widget::CreateWindowWithParent(this, parent_window)->Show(); |
| 71 } | 71 } |
| 72 | 72 |
| 73 RestartMessageBox::~RestartMessageBox() { | 73 RestartMessageBox::~RestartMessageBox() { |
| 74 } | 74 } |
| OLD | NEW |