Fix terminal keyboard open + sticky outside-click

This commit is contained in:
Soham Sharma 2026-04-16 19:36:42 +08:00
commit 0f034b8528
2 changed files with 19 additions and 6 deletions

View file

@ -1041,12 +1041,16 @@ class AppDelegate: NSObject, NSApplicationDelegate {
guard Defaults[.enableShortcuts], Defaults[.enableTerminalFeature] else { return }
if vm.notchState == .closed {
closeNotchWorkItem?.cancel()
closeNotchWorkItem = nil
vm.open()
coordinator.currentView = .terminal
} else {
if coordinator.currentView == .terminal {
vm.close()
} else {
closeNotchWorkItem?.cancel()
closeNotchWorkItem = nil
coordinator.currentView = .terminal
}
}