diff --git a/apps/macos/Sources/Clawdis/WebChatWindow.swift b/apps/macos/Sources/Clawdis/WebChatWindow.swift index 783bf1100..9dac038dc 100644 --- a/apps/macos/Sources/Clawdis/WebChatWindow.swift +++ b/apps/macos/Sources/Clawdis/WebChatWindow.swift @@ -322,6 +322,11 @@ final class WebChatWindowController: NSWindowController, WKNavigationDelegate, N self.notifyPanelClosedOnce() } + func windowWillClose(_ notification: Notification) { + guard case .panel = self.presentation else { return } + self.notifyPanelClosedOnce() + } + private func notifyPanelClosedOnce() { guard !self.panelCloseNotified else { return } self.panelCloseNotified = true