pull/223/head
Ruben Daniels 2015-10-28 17:36:59 -07:00 zatwierdzone przez nightwing
rodzic a52b93b35d
commit 9bb4f1d886
3 zmienionych plików z 16 dodań i 7 usunięć

Wyświetl plik

@ -108,10 +108,16 @@ define(function(require, module, exports) {
}
else {
tab.aml.on("afterclose", function(){
setTimeout(function(){
if (tab.meta.$closeSync) {
tab.unload(e);
closing--;
});
}
else {
setTimeout(function(){
tab.unload(e);
closing--;
});
}
});
}
},

Wyświetl plik

@ -280,7 +280,9 @@ define(function(require, module, exports) {
// @todo Explain difference with unload in docs
function close(noAnim) {
if (!amlPane.remove) return false;
amlPane.remove(amlTab, null, noAnim);
return true;
}
/***** Lifecycle *****/
@ -291,10 +293,8 @@ define(function(require, module, exports) {
plugin.on("beforeUnload", function(){
if (!plugin.meta.$closing) {
plugin.document.meta.$ignoreSave = true;
close();
delete plugin.document.meta.$ignoreSave;
return false;
if (close())
return false;
}
});

Wyświetl plik

@ -787,7 +787,10 @@ define(function(require, module, exports) {
var pane = list[i], nodes = pane.getTabs();
for (var j = nodes.length - 1; j >= 0; j--) {
var tab = nodes[j];
if (!soft) tab.unload();
if (!soft) {
tab.meta.$closeSync = true;
tab.unload();
}
else {
tab.aml.parentNode.removeChild(tab.aml);
tab.pane = null;