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 #include "chrome/browser/ui/cocoa/tab_modal_confirm_dialog_mac.h" | 5 #include "chrome/browser/ui/cocoa/tab_modal_confirm_dialog_mac.h" |
6 | 6 |
7 #include "base/mac/scoped_nsobject.h" | 7 #include "base/mac/scoped_nsobject.h" |
8 #include "chrome/browser/ui/browser_dialogs.h" | 8 #include "chrome/browser/ui/browser_dialogs.h" |
9 #import "chrome/browser/ui/cocoa/constrained_window/constrained_window_alert.h" | 9 #import "chrome/browser/ui/cocoa/constrained_window/constrained_window_alert.h" |
10 #import "chrome/browser/ui/cocoa/constrained_window/constrained_window_custom_sh
eet.h" | 10 #import "chrome/browser/ui/cocoa/constrained_window/constrained_window_custom_sh
eet.h" |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 } | 107 } |
108 | 108 |
109 void TabModalConfirmDialogMac::SetPreventCloseOnLoadStart(bool prevent) { | 109 void TabModalConfirmDialogMac::SetPreventCloseOnLoadStart(bool prevent) { |
110 window_->SetPreventCloseOnLoadStart(prevent); | 110 window_->SetPreventCloseOnLoadStart(prevent); |
111 } | 111 } |
112 | 112 |
113 void TabModalConfirmDialogMac::OnConstrainedWindowClosed( | 113 void TabModalConfirmDialogMac::OnConstrainedWindowClosed( |
114 ConstrainedWindowMac* window) { | 114 ConstrainedWindowMac* window) { |
115 // Provide a disposition in case the dialog was closed without accepting or | 115 // Provide a disposition in case the dialog was closed without accepting or |
116 // cancelling. | 116 // cancelling. |
117 delegate_->Cancel(); | 117 delegate_->Close(); |
118 delete this; | 118 delete this; |
119 } | 119 } |
OLD | NEW |