summaryrefslogtreecommitdiff
path: root/macos
diff options
context:
space:
mode:
authorhimura467 <mitarashidango0927@gmail.com>2025-09-29 00:00:41 +0900
committerhimura467 <mitarashidango0927@gmail.com>2025-09-29 00:00:41 +0900
commit8151f4bbf5ef90fc404a096c0bc33f910bc1311f (patch)
tree3b281c14b8c367e31dbd738a49f8e31de87ede6f /macos
parent9d33545a55e4a2ed3346408ef3acf50e80964e29 (diff)
feat: focusSurface for quick terminal
Diffstat (limited to 'macos')
-rw-r--r--macos/Sources/Features/QuickTerminal/QuickTerminalController.swift12
1 files changed, 12 insertions, 0 deletions
diff --git a/macos/Sources/Features/QuickTerminal/QuickTerminalController.swift b/macos/Sources/Features/QuickTerminal/QuickTerminalController.swift
index 65186c5d7..c7080d7de 100644
--- a/macos/Sources/Features/QuickTerminal/QuickTerminalController.swift
+++ b/macos/Sources/Features/QuickTerminal/QuickTerminalController.swift
@@ -247,6 +247,18 @@ class QuickTerminalController: BaseTerminalController {
// MARK: Base Controller Overrides
+ override func focusSurface(_ view: Ghostty.SurfaceView) {
+ if visible {
+ // If we're visible, we just focus the surface as normal.
+ super.focusSurface(view)
+ return
+ }
+ animateIn()
+ DispatchQueue.main.asyncAfter(deadline: .now() + derivedConfig.quickTerminalAnimationDuration) {
+ super.focusSurface(view)
+ }
+ }
+
override func surfaceTreeDidChange(from: SplitTree<Ghostty.SurfaceView>, to: SplitTree<Ghostty.SurfaceView>) {
super.surfaceTreeDidChange(from: from, to: to)