mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-29 11:42:17 +00:00
fix(desktop): keep auxiliary overlays out of host wiring
Skip the privileged bridge and session-end wiring for child overlays before their renderer loads, in addition to the trusted-URL check on the transport port. User decisions: - Keep the top-center Disconnected pill above the live page
This commit is contained in:
parent
6db25efbe5
commit
dcf9dd923e
2 changed files with 2 additions and 1 deletions
|
|
@ -58,6 +58,7 @@ export const registerIpcHandlers = Effect.gen(function* () {
|
|||
}
|
||||
|
||||
const wire = (win: BrowserWindow) => {
|
||||
if (isAuxiliaryWindow(win) || win.getParentWindow()) return
|
||||
win.webContents.on("before-input-event", (_event, input) => {
|
||||
// Ctrl+R renames the session and Ctrl+Shift+R toggles review in the renderer,
|
||||
// so the default menu's Reload and Force Reload must not take them.
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ export const layer = Layer.effect(
|
|||
)
|
||||
|
||||
const wire = (_event: Electron.Event | undefined, win: BrowserWindow) => {
|
||||
if (!isAuxiliaryWindow(win)) win.on("session-end", storage.flush)
|
||||
if (!isAuxiliaryWindow(win) && !win.getParentWindow()) win.on("session-end", storage.flush)
|
||||
}
|
||||
|
||||
app.on("before-quit", storage.flush)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue