feat: focusSurface for quick terminal

This commit is contained in:
himura467
2025-09-29 00:00:41 +09:00
parent 9d33545a55
commit 8151f4bbf5

View File

@@ -247,6 +247,18 @@ class QuickTerminalController: BaseTerminalController {
// MARK: Base Controller Overrides // 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>) { override func surfaceTreeDidChange(from: SplitTree<Ghostty.SurfaceView>, to: SplitTree<Ghostty.SurfaceView>) {
super.surfaceTreeDidChange(from: from, to: to) super.surfaceTreeDidChange(from: from, to: to)