Add e.returnValue in addEventListener('beforeunload') for sake of Firefox

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2680 eee81c28-f429-11dd-99c0-75d572ba1ddd
master
Brett Zamir 2014-02-10 13:45:48 +00:00
parent 00092d4a03
commit 6e5905370d
1 changed files with 1 additions and 0 deletions

View File

@ -4578,6 +4578,7 @@
// showSaveWarning is set to 'false' when the page is saved.
if (!curConfig.no_save_warning && Editor.showSaveWarning) {
// Browser already asks question about closing the page
e.returnValue = uiStrings.notification.unsavedChanges; // Firefox needs this when beforeunload set by addEventListener (even though message is not used)
return uiStrings.notification.unsavedChanges;
}
}, false);