fix(theseus): quiet add-ons hide from the dock on a fresh profile
autoHideQuietDock ran only when the sidebar state was pushed; on a fresh boot the chrome pulls it, so Shield and Cookie Pop-ups showed in the dock until something re-emitted. Run it on the pull path too. (cherry picked from commit 4f489303f3591444980f0f456b1672fcbf3dae7a)
This commit is contained in:
parent
0f9209e1a9
commit
5388858a65
1 changed files with 3 additions and 1 deletions
4
main.js
4
main.js
|
|
@ -2606,6 +2606,9 @@ function toggleSidebar() { setSidebar(!sidebarVisible); }
|
||||||
// Everything the chrome needs to draw the extension dock + plug-in row:
|
// Everything the chrome needs to draw the extension dock + plug-in row:
|
||||||
// panels, toolbar menus, which panel is open, and the user's dock prefs.
|
// panels, toolbar menus, which panel is open, and the user's dock prefs.
|
||||||
function sidebarStatePayload() {
|
function sidebarStatePayload() {
|
||||||
|
// Runs on the pull path too (the chrome asks at boot), not only on pushes —
|
||||||
|
// a fresh profile otherwise showed the quiet add-ons until something re-emitted.
|
||||||
|
try { autoHideQuietDock(); } catch {}
|
||||||
return {
|
return {
|
||||||
visible: sidebarVisible,
|
visible: sidebarVisible,
|
||||||
active: sidebarActivePanelId,
|
active: sidebarActivePanelId,
|
||||||
|
|
@ -2635,7 +2638,6 @@ function autoHideQuietDock() {
|
||||||
if (changed) { settings.dockHidden = [...hidden]; settings.dockAutoHidden = [...seen]; saveSettings(); }
|
if (changed) { settings.dockHidden = [...hidden]; settings.dockAutoHidden = [...seen]; saveSettings(); }
|
||||||
}
|
}
|
||||||
function emitSidebarState() {
|
function emitSidebarState() {
|
||||||
try { autoHideQuietDock(); } catch {}
|
|
||||||
try { chrome?.webContents.send("sidebar-state", sidebarStatePayload()); } catch {}
|
try { chrome?.webContents.send("sidebar-state", sidebarStatePayload()); } catch {}
|
||||||
}
|
}
|
||||||
function setSidebar(show, panelId) {
|
function setSidebar(show, panelId) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue