mirror of
https://github.com/zen-browser/desktop.git
synced 2026-07-17 06:01:06 +00:00
gh-13149: Fixed WS marking tabs as inactive in certain cases (gh-13298)
This commit is contained in:
@@ -795,6 +795,16 @@ class nsZenWindowSync {
|
||||
);
|
||||
return false;
|
||||
}
|
||||
// Theoretical case where we are trying to swap two tabs in the same window.
|
||||
// There has been some reports of this happening in the wild, and while it shouldn't
|
||||
// cause any critical issues, it can cause some weird states and we should avoid it.
|
||||
// For example, see gh-13149
|
||||
if (aOtherTab.ownerGlobal === aOurTab.ownerGlobal) {
|
||||
this.log(
|
||||
`Cannot swap browsers between tabs ${aOurTab.id} and ${aOtherTab.id} because they are in the same window`
|
||||
);
|
||||
return false;
|
||||
}
|
||||
// Can't swap between chrome and content processes.
|
||||
if (
|
||||
aOurTab.linkedBrowser.isRemoteBrowser !=
|
||||
|
||||
Reference in New Issue
Block a user