Skip to content

Commit ffab4a8

Browse files
committed
feat: Always mantain hover state after using app commands for switching workspaces, b=no-bug, c=workspaces
1 parent ebd1910 commit ffab4a8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/zen/workspaces/ZenWorkspaces.mjs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -524,7 +524,7 @@ var gZenWorkspaces = new (class extends ZenMultiWindowFeature {
524524

525525
_handleAppCommand(event) {
526526
// note: Dont use this._hoveringSidebar as it's not as reliable as checking for :hover
527-
if (!this.workspaceEnabled || !gNavToolbox.matches(':hover')) {
527+
if (!this.workspaceEnabled || !this._hoveringSidebar) {
528528
return;
529529
}
530530

@@ -542,6 +542,9 @@ var gZenWorkspaces = new (class extends ZenMultiWindowFeature {
542542
event.preventDefault();
543543
break;
544544
}
545+
requestAnimationFrame(() => {
546+
gNavToolbox.setAttribute('zen-has-hover', 'true');
547+
});
545548
}
546549

547550
_setupSidebarHandlers() {

0 commit comments

Comments
 (0)