mirror of
https://github.com/zen-browser/components.git
synced 2025-07-08 17:49:58 +02:00
Refactor ZenWorkspaces to handle changing workspaces and update context menu
This commit is contained in:
parent
1396523f3b
commit
600d0d7149
1 changed files with 3 additions and 2 deletions
|
@ -141,7 +141,8 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
|
||||||
activeWorkspace = workspaces.workspaces[0];
|
activeWorkspace = workspaces.workspaces[0];
|
||||||
Services.prefs.setStringPref('zen.workspaces.active', activeWorkspace.uuid);
|
Services.prefs.setStringPref('zen.workspaces.active', activeWorkspace.uuid);
|
||||||
}
|
}
|
||||||
this.changeWorkspace(activeWorkspace, true);
|
await SessionStore.promiseInitialized;
|
||||||
|
await this.changeWorkspace(activeWorkspace, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -730,10 +731,10 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let activeWorkspace = await parent.ZenWorkspaces.getActiveWorkspace();
|
let activeWorkspace = await parent.ZenWorkspaces.getActiveWorkspace();
|
||||||
|
this._lastSelectedWorkspaceTabs[workspaceID] = tab;
|
||||||
if (workspaceID === activeWorkspace.uuid) {
|
if (workspaceID === activeWorkspace.uuid) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this._lastSelectedWorkspaceTabs[workspaceID] = tab;
|
|
||||||
await parent.ZenWorkspaces.changeWorkspace({ uuid: workspaceID });
|
await parent.ZenWorkspaces.changeWorkspace({ uuid: workspaceID });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue