summaryrefslogtreecommitdiffstats
path: root/chrome/browser/js_modal_dialog_mac.mm
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/js_modal_dialog_mac.mm')
-rw-r--r--chrome/browser/js_modal_dialog_mac.mm7
1 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/js_modal_dialog_mac.mm b/chrome/browser/js_modal_dialog_mac.mm
index 44eb86e..3bdc9aa 100644
--- a/chrome/browser/js_modal_dialog_mac.mm
+++ b/chrome/browser/js_modal_dialog_mac.mm
@@ -172,3 +172,10 @@ NativeDialog JavaScriptAppModalDialog::CreateNativeDialog() {
NOTIMPLEMENTED();
return nil;
}
+
+void JavaScriptAppModalDialog::CloseModalDialog() {
+ NSAlert* alert = dialog_;
+ DCHECK([alert isKindOfClass:[NSAlert class]]);
+ [NSApp endSheet:[alert window]];
+ dialog_ = nil;
+}