Chromium Code Reviews| 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 #ifndef CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ | 5 #ifndef CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ |
| 6 #define CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ | 6 #define CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ |
| 7 | 7 |
| 8 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
| 9 #include "ui/gfx/native_widget_types.h" | 9 #include "ui/gfx/native_widget_types.h" |
| 10 | 10 |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 54 // | 54 // |
| 55 // NOTE: In general, you should avoid this since it's usually poor UI. | 55 // NOTE: In general, you should avoid this since it's usually poor UI. |
| 56 // We have a variety of other surfaces such as app menu notifications and | 56 // We have a variety of other surfaces such as app menu notifications and |
| 57 // infobars; consult the UI leads for a recommendation. | 57 // infobars; consult the UI leads for a recommendation. |
| 58 MessageBoxResult ShowMessageBoxWithButtonText(gfx::NativeWindow parent, | 58 MessageBoxResult ShowMessageBoxWithButtonText(gfx::NativeWindow parent, |
| 59 const base::string16& title, | 59 const base::string16& title, |
| 60 const base::string16& message, | 60 const base::string16& message, |
| 61 const base::string16& yes_text, | 61 const base::string16& yes_text, |
| 62 const base::string16& no_text); | 62 const base::string16& no_text); |
| 63 | 63 |
| 64 // Closes the current message box, if any, accepting or declining based on | |
| 65 // |accept|. Returns whether there was a message box showing. | |
| 66 bool CloseMessageBoxForTest(bool accept); | |
|
Daniel Erat
2016/10/27 17:23:19
nit: consider WARN_UNUSED_RESULT if tests ought to
Evan Stade
2016/10/27 19:11:18
Done.
| |
| 67 | |
| 64 } // namespace chrome | 68 } // namespace chrome |
| 65 | 69 |
| 66 #endif // CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ | 70 #endif // CHROME_BROWSER_UI_SIMPLE_MESSAGE_BOX_H_ |
| OLD | NEW |