[Pkg-mozext-commits] [tabmixplus] 12/28: Don't remove all backup when new provate window is open, Don't remove existin crashed data when user disabled backup, add missing crashed session data when new session opened with single private window.
David Prévot
taffit at moszumanska.debian.org
Sun Jul 5 15:02:34 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository tabmixplus.
commit aefd871ee511257b9470ad7cd6e6a7444a5c58ee
Author: onemen <tabmix.onemen at gmail.com>
Date: Tue Jun 23 10:58:48 2015 +0300
Don't remove all backup when new provate window is open, Don't remove existin crashed data when user disabled backup, add missing crashed session data when new session opened with single private window.
---
chrome/content/session/session.js | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/chrome/content/session/session.js b/chrome/content/session/session.js
index c47473c..ca09d69 100644
--- a/chrome/content/session/session.js
+++ b/chrome/content/session/session.js
@@ -360,10 +360,10 @@ var TabmixSessionManager = { // jshint ignore:line
this.toggleRecentlyClosedWindowsButton();
if (this.isPrivateWindow) {
+ this.enableBackup = false;
this.updateSettings();
this.setLiteral(this.gThisWin, "dontLoad", "true");
this.setLiteral(this.gThisWin, "private", "true");
- this.enableBackup = false;
// initialize closed window list broadcaster
let disabled = this.enableManager ? isFirstWindow || this.isPrivateSession || this.isClosedWindowsEmpty() :
TabmixSvc.ss.getClosedWindowCount() === 0;
@@ -738,7 +738,6 @@ var TabmixSessionManager = { // jshint ignore:line
windowSaved = true;
} else { // remove all backup
this.deleteSession(this.gSessionPath[0], "status", "backup");
- this.deleteSession(this.gSessionPath[3]);
this.initSession(this.gSessionPath[0], this.gThisWin);
this.saveStateDelayed();
}
@@ -2095,6 +2094,8 @@ if (container == "error") { Tabmix.log("wrapContainer error path " + path + "\n"
this.setLiteral(rdfNodeWindow, "dontLoad", "true");
}
this.deleteArrayNodes(sessionContainer, nodeToDelete, false);
+ let count = this.countWinsAndTabs(crashedContainer);
+ this.setLiteral(this.gSessionPath[3], "nameExt", this.getNameData(count.win, count.tab));
} // if firefox was crashed in middle of crash Recovery try again to restore the same data
else if (!this.containerEmpty(this.gSessionPath[0]))
this.deleteWithProp(sessionContainer);
@@ -2126,9 +2127,11 @@ if (container == "error") { Tabmix.log("wrapContainer error path " + path + "\n"
this.callBackData = {label: null, whattoLoad: "session"};
this.waitForCallBack = true;
if (!this.containerEmpty(this.gSessionPath[3])) { // if Crashed Session is not empty
- let crashedContainer = this.initContainer(this.gSessionPath[3]);
- let count = this.countWinsAndTabs(crashedContainer);
- this.setLiteral(this.gSessionPath[3], "nameExt", this.getNameData(count.win, count.tab));
+ if (!this.nodeHasArc(this.gSessionPath[3], "nameExt")) {
+ let crashedContainer = this.initContainer(this.gSessionPath[3]);
+ let count = this.countWinsAndTabs(crashedContainer);
+ this.setLiteral(this.gSessionPath[3], "nameExt", this.getNameData(count.win, count.tab));
+ }
if (this.enableManager && !isAllEmpty) {
msg += "\n\n" + TabmixSvc.getSMString("sm.afterCrash.msg1");
buttons = [TabmixSvc.setLabel("sm.afterCrash.button0"),
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/tabmixplus.git
More information about the Pkg-mozext-commits
mailing list