Emit WindowCloseCancelled message when close is cancelled by user code.

This commit is contained in:
Cheng Zhao 2013-06-26 15:35:10 +08:00
parent adacc2bcf9
commit 411e1a3685

View file

@ -151,8 +151,10 @@ void NativeWindow::CloseWebContents() {
FOR_EACH_OBSERVER(NativeWindowObserver,
observers_,
WillCloseWindow(&prevent_default));
if (prevent_default)
if (prevent_default) {
WindowList::WindowCloseCancelled(this);
return;
}
content::WebContents* web_contents(GetWebContents());