[Pkg-mozext-commits] [tabmixplus] 13/28: Restore to New Window(s) from private window opens new private window without restoring any tab

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 554bd37c37ffc102339b1433680ddc71235c8a76
Author: onemen <tabmix.onemen at gmail.com>
Date:   Tue Jun 23 12:36:33 2015 +0300

    Restore to New Window(s) from private window opens new private window without restoring any tab
---
 chrome/content/session/session.js | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/chrome/content/session/session.js b/chrome/content/session/session.js
index ca09d69..906de09 100644
--- a/chrome/content/session/session.js
+++ b/chrome/content/session/session.js
@@ -364,14 +364,9 @@ var TabmixSessionManager = { // jshint ignore:line
          this.updateSettings();
          this.setLiteral(this.gThisWin, "dontLoad", "true");
          this.setLiteral(this.gThisWin, "private", "true");
-         // initialize closed window list broadcaster
-         let disabled = this.enableManager ? isFirstWindow || this.isPrivateSession || this.isClosedWindowsEmpty() :
-                                             TabmixSvc.ss.getClosedWindowCount() === 0;
-         Tabmix.setItem("tmp_closedwindows", "disabled", disabled || null);
-         return;
       }
 
-      if (isFirstWindow) {
+      if (!this.isPrivateWindow && isFirstWindow) {
          // if this isn't delete on exit, we know next time that firefox crash
          this.prefBranch.setBoolPref("crashed" , true); // we use this in setup.js;
          Services.prefs.savePrefFile(null); // store the pref immediately
@@ -421,11 +416,13 @@ var TabmixSessionManager = { // jshint ignore:line
          this.copyClosedTabsToRDF(this.gThisWin);
       }
       // initialize closed window list broadcaster
-      var disabled = this.enableManager ? Tabmix.firstWindowInSession || this.isClosedWindowsEmpty() :
+      var status = this.isPrivateWindow ? isFirstWindow || this.isPrivateSession : Tabmix.firstWindowInSession;
+      var disabled = this.enableManager ? status || this.isClosedWindowsEmpty() :
                                           TabmixSvc.ss.getClosedWindowCount() === 0;
       Tabmix.setItem("tmp_closedwindows", "disabled", disabled || null);
 
-      this.saveStateDelayed();
+      if (!this.isPrivateWindow)
+         this.saveStateDelayed();
    },
 
    // we call this function after session restored by sessionStore, after restart or after exit private-browsing

-- 
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