From 97a0afea4c77b465c5f069f993e7aacd6598367e Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Tue, 16 Feb 2016 17:37:32 -0600 Subject: [PATCH] Repair tearing off a tree of multiple tabs --- content/treestyletab/windowHelper.js | 2 +- modules/window.js | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/content/treestyletab/windowHelper.js b/content/treestyletab/windowHelper.js index 1d2e301f..d6b33c9b 100644 --- a/content/treestyletab/windowHelper.js +++ b/content/treestyletab/windowHelper.js @@ -114,7 +114,7 @@ var TreeStyleTabWindowHelper = { gBrowser.__treestyletab__swapBrowsersAndCloseOther = gBrowser.swapBrowsersAndCloseOther; gBrowser.swapBrowsersAndCloseOther = function(...args) { if (TreeStyleTabWindowHelper.runningDelayedStartup && - TreeStyleTabService.tearOffSubtreeFromRemote()) + TreeStyleTabService.tearOffSubtreeFromRemote(...args)) return; return gBrowser.__treestyletab__swapBrowsersAndCloseOther.apply(this, args); }; diff --git a/modules/window.js b/modules/window.js index 5624ac55..f3eec853 100644 --- a/modules/window.js +++ b/modules/window.js @@ -1870,10 +1870,9 @@ TreeStyleTabWindow.prototype = inherit(TreeStyleTabBase, { }, _tabFocusAllowance : [], - tearOffSubtreeFromRemote : function TSTWindow_tearOffSubtreeFromRemote() + tearOffSubtreeFromRemote : function TSTWindow_tearOffSubtreeFromRemote(ourTab, remoteTab) { var w = this.window; - var remoteTab = w.arguments[0]; var remoteWindow = remoteTab.ownerDocument.defaultView; var remoteService = remoteWindow.TreeStyleTabService; var remoteMultipleTabService = remoteWindow.MultipleTabService;