forked from ZenBrowserMirrors/zen-desktop
Refactor tab handling in ZenGlanceManager and update tab filtering logic for improved performance
This commit is contained in:
parent
61190233fc
commit
093074a9fc
2 changed files with 27 additions and 16 deletions
|
@ -245,7 +245,8 @@
|
|||
this.overlay.style.pointerEvents = 'none';
|
||||
this.quickCloseGlance({ justAnimateParent: true, clearID: false });
|
||||
const originalPosition = this.#glances.get(this.#currentGlanceID).originalPosition;
|
||||
gZenUIManager.motion.animate(
|
||||
gZenUIManager.motion
|
||||
.animate(
|
||||
this.#currentParentTab.linkedBrowser.closest('.browserSidebarContainer'),
|
||||
{
|
||||
scale: [0.98, 1],
|
||||
|
@ -257,7 +258,8 @@
|
|||
type: 'spring',
|
||||
bounce: 0.2,
|
||||
}
|
||||
).then(() => {
|
||||
)
|
||||
.then(() => {
|
||||
this.#currentParentTab.linkedBrowser.closest('.browserSidebarContainer').removeAttribute('style');
|
||||
});
|
||||
gZenUIManager.motion
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
diff --git a/browser/components/tabbrowser/content/tabbrowser.js b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..8063e0149827bb3da06b25079efa2a5a6fdfbb3a 100644
|
||||
index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..cca93dc8fe6300a5bee22029bbe2369e9240ba35 100644
|
||||
--- a/browser/components/tabbrowser/content/tabbrowser.js
|
||||
+++ b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
@@ -406,11 +406,39 @@
|
||||
|
@ -196,6 +196,15 @@ index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..8063e0149827bb3da06b25079efa2a5a
|
|||
if (
|
||||
!bulkOrderedOpen &&
|
||||
((openerTab &&
|
||||
@@ -3780,7 +3859,7 @@
|
||||
}
|
||||
|
||||
/** @type {MozTabbrowserTab|undefined} */
|
||||
- let tabAfter = this.tabs.at(index);
|
||||
+ let tabAfter = this.tabs.filter(tab => !tab.hasAttribute("zen-glance-tab")).at(index);
|
||||
this.tabContainer._invalidateCachedTabs();
|
||||
|
||||
if (tabGroup) {
|
||||
@@ -4095,6 +4174,9 @@
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue