mirror of
https://github.com/zen-browser/desktop.git
synced 2025-10-08 02:46:35 +00:00
Fixed creating a new tab when we can just select the last one when switching workspaces
This commit is contained in:
@@ -1480,7 +1480,10 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
|
|||||||
}
|
}
|
||||||
// Find first suitable tab
|
// Find first suitable tab
|
||||||
else {
|
else {
|
||||||
tabToSelect = Array.from(visibleTabs).find((tab) => this._shouldShowTab(tab, window.uuid, containerId, workspaces));
|
tabToSelect = Array.from(visibleTabs).find((tab) => !tab.pinned);
|
||||||
|
if (!tabToSelect && visibleTabs.length) {
|
||||||
|
tabToSelect = Array.from(visibleTabs)[visibleTabs.length - 1];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const previousSelectedTab = gBrowser.selectedTab;
|
const previousSelectedTab = gBrowser.selectedTab;
|
||||||
|
Reference in New Issue
Block a user