mirror-ghostty/macos/Sources/Features/Terminal
Mitchell Hashimoto c8243ffd99
macOS: prevent focus loss in hidden titlebar + non-native fullscreen
When using hidden titlebar with non-native fullscreen, the window would
lose focus after entering the first command. This occurred because:

1. Shell commands update the window title
2. Title changes trigger reapplyHiddenStyle() 
3. reapplyHiddenStyle() re-adds .titled to the style mask
4. Style mask changes during fullscreen confuse AppKit, causing focus loss

Fixed by adding a guard to skip titlebar restyling while fullscreen is
active, using terminalController.fullscreenStyle.isFullscreen for
proper detection of both native and non-native fullscreen modes.

https://ampcode.com/threads/T-c4ef59cc-1232-4fa5-8f09-c65724ee84d3
2025-09-03 10:01:28 -07:00
..
Window Styles macOS: prevent focus loss in hidden titlebar + non-native fullscreen 2025-09-03 10:01:28 -07:00
BaseTerminalController.swift macOS: order out alert sheets to avoid Stage Manager focus loss 2025-08-22 09:05:20 -07:00
ErrorView.swift style(macos): cleanup trailing spaces 2024-08-21 21:53:09 +02:00
TerminalController.swift macOS: SurfaceView should implement Identifiable 2025-09-03 09:17:37 -07:00
TerminalRestorable.swift macOS: SurfaceView should implement Identifiable 2025-09-03 09:17:37 -07:00
TerminalView.swift macos: AX for debug warning 2025-06-15 07:56:05 -07:00