Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(159)

Side by Side Diff: chrome/browser/ui/cocoa/tab_modal_confirm_dialog_mac.mm

Issue 18179004: Dismiss action in tab modal dialogs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase, fix CrOS build Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
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 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698