refactor: enhance tab handling in split view and update script loading method

This commit is contained in:
mr. m 2025-03-29 12:31:00 +01:00
parent 12edc9279c
commit 5462f035f8
No known key found for this signature in database
GPG key ID: 419302196C23B258
4 changed files with 139 additions and 85 deletions

View file

@ -1,8 +1,8 @@
diff --git a/browser/components/tabbrowser/content/tabbrowser.js b/browser/components/tabbrowser/content/tabbrowser.js
index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2b4b44527 100644
index 5f406ea5d09273c9b70b84eee24c6267f88692f8..52e9414c9b6606510538a9f565cb0035ace83e08 100644
--- a/browser/components/tabbrowser/content/tabbrowser.js
+++ b/browser/components/tabbrowser/content/tabbrowser.js
@@ -424,11 +424,50 @@
@@ -424,11 +424,66 @@
return this.tabContainer.visibleTabs;
}
@ -19,6 +19,22 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
+ return i;
+ }
+
+ get _numVisiblePinTabsWithFolders() {
+ let i = 0;
+ for (let tab of this.tabs) {
+ if (!tab.pinned && !tab.hasAttribute("zen-glance-tab")) {
+ break;
+ }
+ if (!tab.hidden) {
+ i += !tab.hasAttribute("zen-glance-tab");
+ }
+ if (tab.group?.tabs[0] == tab) {
+ i++;
+ }
+ }
+ return i;
+ }
+
+ get _numZenEssentials() {
+ let i = 0;
+ for (let tab of this.tabs) {
@ -55,7 +71,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
}
return i;
}
@@ -558,6 +597,7 @@
@@ -558,6 +613,7 @@
this.tabpanels.appendChild(panel);
let tab = this.tabs[0];
@ -63,7 +79,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
tab.linkedPanel = uniqueId;
this._selectedTab = tab;
this._selectedBrowser = browser;
@@ -823,11 +863,13 @@
@@ -823,11 +879,13 @@
}
this.showTab(aTab);
@ -80,7 +96,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
this.moveTabTo(aTab, this.pinnedTabCount, { forceStandaloneTab: true });
}
aTab.setAttribute("pinned", "true");
@@ -841,12 +883,15 @@
@@ -841,12 +899,15 @@
}
if (this.tabContainer.verticalMode) {
@ -97,7 +113,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
});
} else {
this.moveTabTo(aTab, this.pinnedTabCount - 1, {
@@ -1029,6 +1074,8 @@
@@ -1029,6 +1090,8 @@
let LOCAL_PROTOCOLS = ["chrome:", "about:", "resource:", "data:"];
@ -106,7 +122,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (
aIconURL &&
!aLoadingPrincipal &&
@@ -1039,6 +1086,9 @@
@@ -1039,6 +1102,9 @@
);
return;
}
@ -116,7 +132,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
let browser = this.getBrowserForTab(aTab);
browser.mIconURL = aIconURL;
@@ -1287,6 +1337,7 @@
@@ -1287,6 +1353,7 @@
if (!this._previewMode) {
newTab.recordTimeFromUnloadToReload();
newTab.updateLastAccessed();
@ -124,7 +140,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
oldTab.updateLastAccessed();
// if this is the foreground window, update the last-seen timestamps.
if (this.ownerGlobal == BrowserWindowTracker.getTopWindow()) {
@@ -1439,6 +1490,9 @@
@@ -1439,6 +1506,9 @@
}
let activeEl = document.activeElement;
@ -134,7 +150,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
// If focus is on the old tab, move it to the new tab.
if (activeEl == oldTab) {
newTab.focus();
@@ -1762,7 +1816,7 @@
@@ -1762,7 +1832,7 @@
}
_setTabLabel(aTab, aLabel, { beforeTabOpen, isContentTitle, isURL } = {}) {
@ -143,7 +159,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
return false;
}
@@ -1865,7 +1919,7 @@
@@ -1865,7 +1935,7 @@
newIndex = this.selectedTab._tPos + 1;
}
@ -152,7 +168,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
let browser;
if (targetTab) {
browser = this.getBrowserForTab(targetTab);
@@ -2122,6 +2176,7 @@
@@ -2122,6 +2192,7 @@
uriIsAboutBlank,
userContextId,
skipLoad,
@ -160,7 +176,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} = {}) {
let b = document.createXULElement("browser");
// Use the JSM global to create the permanentKey, so that if the
@@ -2195,8 +2250,7 @@
@@ -2195,8 +2266,7 @@
// we use a different attribute name for this?
b.setAttribute("name", name);
}
@ -170,7 +186,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
b.setAttribute("transparent", "true");
}
@@ -2373,7 +2427,7 @@
@@ -2373,7 +2443,7 @@
let panel = this.getPanel(browser);
let uniqueId = this._generateUniquePanelID();
@ -179,7 +195,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
aTab.linkedPanel = uniqueId;
// Inject the <browser> into the DOM if necessary.
@@ -2432,8 +2486,8 @@
@@ -2432,8 +2502,8 @@
// If we transitioned from one browser to two browsers, we need to set
// hasSiblings=false on both the existing browser and the new browser.
if (this.tabs.length == 2) {
@ -190,7 +206,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} else {
aTab.linkedBrowser.browsingContext.hasSiblings = this.tabs.length > 1;
}
@@ -2655,6 +2709,7 @@
@@ -2655,6 +2725,7 @@
schemelessInput,
hasValidUserGestureActivation = false,
textDirectiveUserActivation = false,
@ -198,7 +214,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} = {}
) {
// all callers of addTab that pass a params object need to pass
@@ -2665,6 +2720,12 @@
@@ -2665,6 +2736,12 @@
);
}
@ -211,7 +227,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (!UserInteraction.running("browser.tabs.opening", window)) {
UserInteraction.start("browser.tabs.opening", "initting", window);
}
@@ -2728,6 +2789,15 @@
@@ -2728,6 +2805,15 @@
noInitialLabel,
skipBackgroundNotify,
});
@ -227,7 +243,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (insertTab) {
// insert the tab into the tab container in the correct position
this._insertTabAtIndex(t, {
@@ -2752,6 +2822,7 @@
@@ -2752,6 +2838,7 @@
initialBrowsingContextGroupId,
openWindowInfo,
skipLoad,
@ -235,7 +251,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
}));
if (focusUrlBar) {
@@ -2871,6 +2942,9 @@
@@ -2871,6 +2958,9 @@
}
}
@ -245,7 +261,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
// Additionally send pinned tab events
if (pinned) {
this._notifyPinnedStatus(t);
@@ -2891,12 +2965,15 @@
@@ -2891,12 +2981,15 @@
* @param {string} [label=]
* @returns {MozTabbrowserTabGroup}
*/
@ -262,7 +278,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
return group;
}
@@ -2937,6 +3014,7 @@
@@ -2937,6 +3030,7 @@
insertBefore = null,
isUserCreated = false,
telemetryUserCreateSource = "unknown",
@ -270,7 +286,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} = {}
) {
if (!tabs?.length) {
@@ -2951,7 +3029,12 @@
@@ -2951,7 +3045,12 @@
id = `${Date.now()}-${Math.round(Math.random() * 100)}`;
}
let group = this._createTabGroup(id, color, false, label);
@ -284,7 +300,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
group,
insertBefore?.group ?? insertBefore
);
@@ -3268,6 +3351,7 @@
@@ -3268,6 +3367,7 @@
initialBrowsingContextGroupId,
openWindowInfo,
skipLoad,
@ -292,7 +308,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
}
) {
// If we don't have a preferred remote type, and we have a remote
@@ -3331,6 +3415,7 @@
@@ -3331,6 +3431,7 @@
openWindowInfo,
name,
skipLoad,
@ -300,7 +316,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
});
}
@@ -3509,6 +3594,27 @@
@@ -3509,6 +3610,27 @@
) {
tabWasReused = true;
tab = this.selectedTab;
@ -328,7 +344,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (!tabData.pinned) {
this.unpinTab(tab);
} else {
@@ -3522,6 +3628,7 @@
@@ -3522,6 +3644,7 @@
restoreTabsLazily && !select && !tabData.pinned;
let url = "about:blank";
@ -336,7 +352,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (tabData.entries?.length) {
let activeIndex = (tabData.index || tabData.entries.length) - 1;
// Ensure the index is in bounds.
@@ -3557,7 +3664,27 @@
@@ -3557,7 +3680,27 @@
skipLoad: true,
preferredRemoteType,
});
@ -365,7 +381,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (select) {
tabToSelect = tab;
}
@@ -3570,8 +3697,8 @@
@@ -3570,8 +3713,8 @@
// inserted in the DOM. If the tab is not yet in the DOM,
// just insert it in the right place from the start.
if (!tab.parentNode) {
@ -376,7 +392,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
tab.toggleAttribute("pinned", true);
this.tabContainer._invalidateCachedTabs();
// Then ensure all the tab open/pinning information is sent.
@@ -3581,7 +3708,8 @@
@@ -3581,7 +3724,8 @@
// needs calling:
shouldUpdateForPinnedTabs = true;
}
@ -386,7 +402,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
let { groupId } = tabData;
const tabGroup = tabGroupWorkingData.get(groupId);
// if a tab refers to a tab group we don't know, skip any group
@@ -3595,7 +3723,10 @@
@@ -3595,7 +3739,10 @@
tabGroup.stateData.id,
tabGroup.stateData.color,
tabGroup.stateData.collapsed,
@ -398,7 +414,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
);
tabsFragment.appendChild(tabGroup.node);
}
@@ -3646,6 +3777,9 @@
@@ -3646,6 +3793,9 @@
this.selectedTab = tabToSelect;
this.removeTab(leftoverTab);
}
@ -408,7 +424,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (tabs.length > 1 || !tabs[0].selected) {
this._updateTabsAfterInsert();
@@ -3830,7 +3964,7 @@
@@ -3830,7 +3980,7 @@
// Ensure we have an index if one was not provided.
if (typeof index != "number") {
// Move the new tab after another tab if needed, to the end otherwise.
@ -417,7 +433,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (
!bulkOrderedOpen &&
((openerTab &&
@@ -3876,18 +4010,18 @@
@@ -3876,18 +4026,18 @@
// Ensure index is within bounds.
if (tab.pinned) {
@ -440,7 +456,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (tabAfter && tabAfter.group == tabGroup) {
// Place at the front of, or between tabs in, the same tab group
this.tabContainer.insertBefore(tab, tabAfter);
@@ -4199,6 +4333,9 @@
@@ -4199,6 +4349,9 @@
return;
}
@ -450,7 +466,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
this.removeTabs(selectedTabs);
}
@@ -4556,6 +4693,7 @@
@@ -4556,6 +4709,7 @@
skipSessionStore,
} = {}
) {
@ -458,7 +474,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (UserInteraction.running("browser.tabs.opening", window)) {
UserInteraction.finish("browser.tabs.opening", window);
}
@@ -4572,6 +4710,12 @@
@@ -4572,6 +4726,12 @@
TelemetryStopwatch.start("FX_TAB_CLOSE_TIME_NO_ANIM_MS", aTab);
}
@ -471,7 +487,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
// Handle requests for synchronously removing an already
// asynchronously closing tab.
if (!animate && aTab.closing) {
@@ -4586,7 +4730,9 @@
@@ -4586,7 +4746,9 @@
// frame created for it (for example, by updating the visually selected
// state).
let tabWidth = window.windowUtils.getBoundsWithoutFlushing(aTab).width;
@ -482,7 +498,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (
!this._beginRemoveTab(aTab, {
closeWindowFastpath: true,
@@ -4600,7 +4746,6 @@
@@ -4600,7 +4762,6 @@
TelemetryStopwatch.cancel("FX_TAB_CLOSE_TIME_NO_ANIM_MS", aTab);
return;
}
@ -490,7 +506,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
let lockTabSizing =
!this.tabContainer.verticalMode &&
!aTab.pinned &&
@@ -4739,14 +4884,14 @@
@@ -4739,14 +4900,14 @@
!!this.tabsInCollapsedTabGroups.length;
if (
aTab.visible &&
@ -507,7 +523,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (closeWindow) {
// We've already called beforeunload on all the relevant tabs if we get here,
@@ -4770,6 +4915,7 @@
@@ -4770,6 +4931,7 @@
newTab = true;
}
@ -515,7 +531,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
aTab._endRemoveArgs = [closeWindow, newTab];
// swapBrowsersAndCloseOther will take care of closing the window without animation.
@@ -4810,9 +4956,7 @@
@@ -4810,9 +4972,7 @@
aTab._mouseleave();
if (newTab) {
@ -526,7 +542,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} else {
TabBarVisibility.update();
}
@@ -4941,6 +5085,8 @@
@@ -4941,6 +5101,8 @@
this.tabs[i]._tPos = i;
}
@ -535,7 +551,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (!this._windowIsClosing) {
if (wasPinned) {
this.tabContainer._positionPinnedTabs();
@@ -5159,7 +5305,7 @@
@@ -5159,7 +5321,7 @@
!excludeTabs.has(aTab.owner) &&
Services.prefs.getBoolPref("browser.tabs.selectOwnerOnClose")
) {
@ -544,7 +560,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
}
// Try to find a remaining tab that comes after the given tab
@@ -5181,7 +5327,7 @@
@@ -5181,7 +5343,7 @@
}
if (tab) {
@ -553,7 +569,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
}
// If no qualifying visible tab was found, see if there is a tab in
@@ -5599,10 +5745,10 @@
@@ -5599,10 +5761,10 @@
SessionStore.deleteCustomTabValue(aTab, "hiddenBy");
}
@ -566,7 +582,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
aTab.selected ||
aTab.closing ||
// Tabs that are sharing the screen, microphone or camera cannot be hidden.
@@ -5838,7 +5984,7 @@
@@ -5838,7 +6000,7 @@
moveTabTo(aTab, aIndex, { forceStandaloneTab = false } = {}) {
// Don't allow mixing pinned and unpinned tabs.
if (aTab.pinned) {
@ -575,7 +591,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
} else {
aIndex = Math.max(aIndex, this.pinnedTabCount);
}
@@ -5848,10 +5994,17 @@
@@ -5848,10 +6010,17 @@
this.#handleTabMove(aTab, () => {
let neighbor = this.tabs[aIndex];
@ -595,18 +611,21 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
neighbor.after(aTab);
} else {
this.tabContainer.insertBefore(aTab, neighbor);
@@ -5901,6 +6054,10 @@
@@ -5901,6 +6070,13 @@
* Bug 1955388 - prevent pinned tabs from commingling with non-pinned tabs
* when there are hidden tabs present
*/
+ if (targetElement?.group?.hasAttribute("split-view-group")) {
+ targetElement = targetElement.group;
+ }
+ if (tab.group?.hasAttribute("split-view-group")) {
+ tab = tab.group;
+ }
+
if (tab.pinned && !targetElement?.pinned) {
// prevent pinned tab from being dragged past a non-pinned tab
targetElement = this.tabs[this.pinnedTabCount - 1];
@@ -5908,6 +6065,9 @@
@@ -5908,6 +6084,9 @@
}
let getContainer = () => {
@ -616,7 +635,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (tab.pinned && this.tabContainer.verticalMode) {
return this.tabContainer.verticalPinnedTabsContainer;
}
@@ -5937,7 +6097,7 @@
@@ -5937,7 +6116,7 @@
}
moveTabToGroup(aTab, aGroup) {
@ -625,7 +644,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
return;
}
if (aTab.group && aTab.group.id === aGroup.id) {
@@ -5961,6 +6121,10 @@
@@ -5961,6 +6140,10 @@
moveActionCallback();
@ -636,7 +655,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
// Clear tabs cache after moving nodes because the order of tabs may have
// changed.
this.tabContainer._invalidateCachedTabs();
@@ -6015,7 +6179,7 @@
@@ -6015,7 +6198,7 @@
createLazyBrowser,
};
@ -645,7 +664,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
if (aIndex < numPinned || (aTab.pinned && aIndex == numPinned)) {
params.pinned = true;
}
@@ -6765,7 +6929,7 @@
@@ -6765,7 +6948,7 @@
// preventDefault(). It will still raise the window if appropriate.
break;
}
@ -654,7 +673,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
window.focus();
aEvent.preventDefault();
break;
@@ -7671,6 +7835,7 @@
@@ -7671,6 +7854,7 @@
aWebProgress.isTopLevel
) {
this.mTab.setAttribute("busy", "true");
@ -662,7 +681,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
gBrowser._tabAttrModified(this.mTab, ["busy"]);
this.mTab._notselectedsinceload = !this.mTab.selected;
}
@@ -8640,7 +8805,7 @@ var TabContextMenu = {
@@ -8640,7 +8824,7 @@ var TabContextMenu = {
);
contextUnpinSelectedTabs.hidden =
!this.contextTab.pinned || !this.multiselected;
@ -671,7 +690,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
// Move Tab items
let contextMoveTabOptions = document.getElementById(
"context_moveTabOptions"
@@ -8674,7 +8839,7 @@ var TabContextMenu = {
@@ -8674,7 +8858,7 @@ var TabContextMenu = {
let isFirstTab =
!this.contextTabs[0].group &&
(this.contextTabs[0] == visibleTabs[0] ||
@ -680,7 +699,7 @@ index 5f406ea5d09273c9b70b84eee24c6267f88692f8..adc4599c4d1722f8a6a0a636bba074a2
contextMoveTabToStart.disabled = isFirstTab && allSelectedTabsAdjacent;
document.getElementById("context_openTabInWindow").disabled =
@@ -8904,6 +9069,7 @@ var TabContextMenu = {
@@ -8904,6 +9088,7 @@ var TabContextMenu = {
if (this.contextTab.multiselected) {
gBrowser.removeMultiSelectedTabs();
} else {