mirror of
https://github.com/zen-browser/desktop.git
synced 2025-07-10 04:25:31 +02:00
Refactor pinned tab management to improve tab insertion logic and error handling
This commit is contained in:
parent
60e2cab249
commit
20ab35fbf9
4 changed files with 127 additions and 116 deletions
|
@ -267,9 +267,9 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
|
|||
// remove tab from list
|
||||
tabs.splice(tabs.indexOf(tab), 1);
|
||||
if (tab.pinned) {
|
||||
pinnedSection.appendChild(tab);
|
||||
pinnedSection.insertBefore(tab, pinnedSection.lastChild);
|
||||
} else {
|
||||
section.appendChild(tab);
|
||||
section.insertBefore(tab, section.lastChild);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue