Index: chrome/browser/ui/simple_message_box.h |
diff --git a/chrome/browser/ui/simple_message_box.h b/chrome/browser/ui/simple_message_box.h |
index d6f57db1e16a07803ea2eb399ef03d27dc9ea622..dc0ee1a054425cd5d2444e0a225110e765fdbdaf 100644 |
--- a/chrome/browser/ui/simple_message_box.h |
+++ b/chrome/browser/ui/simple_message_box.h |
@@ -11,8 +11,14 @@ |
namespace chrome { |
enum MessageBoxResult { |
- MESSAGE_BOX_RESULT_NO = 0, // User chose NO or CANCEL. |
- MESSAGE_BOX_RESULT_YES = 1, // User chose YES or OK. |
+ MESSAGE_BOX_RESULT_NO = 0, // User chose NO or CANCEL. |
+ MESSAGE_BOX_RESULT_YES = 1, // User chose YES or OK. |
+ |
+ // User chose YES or OK and the checkbox was checked. |
+ MESSAGE_BOX_RESULT_YES_CHECKED = 2, |
+ |
+ // User chose YES or OK and the checkbox was unchecked. |
+ MESSAGE_BOX_RESULT_YES_NOT_CHECKED = 3, |
Lei Zhang
2016/07/09 01:04:47
Can we just use MESSAGE_BOX_RESULT_YES instead?
afakhry
2016/07/11 16:47:45
Makes sense! This is definitely better indeed. Don
|
}; |
enum MessageBoxType { |
@@ -31,6 +37,13 @@ void ShowWarningMessageBox(gfx::NativeWindow parent, |
const base::string16& title, |
const base::string16& message); |
+// As above, but with a checkbox. Returns true if the checkbox was checked when |
+// the dialog was dismissed, false otherwise. |
+bool ShowWarningMessageBoxWithCheckbox(gfx::NativeWindow parent, |
+ const base::string16& title, |
+ const base::string16& message, |
+ const base::string16& checkbox_text); |
+ |
// As above, but two buttons are displayed and the return value indicates which |
// is chosen. |
MessageBoxResult ShowQuestionMessageBox(gfx::NativeWindow parent, |