mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-08-02 14:57:31 +03:00
Rename structs for QuickTerminal Tab
This commit is contained in:
@ -135,7 +135,7 @@ class QuickTerminalController: BaseTerminalController {
|
||||
focusedSurface = leaf.surface
|
||||
|
||||
let mainContent = VStack(spacing: 0) {
|
||||
TabBarView(tabManager: tabManager)
|
||||
QuickTerminalTabBarView(tabManager: tabManager)
|
||||
TerminalView(
|
||||
ghostty: ghostty,
|
||||
viewModel: self,
|
||||
|
@ -1,6 +1,6 @@
|
||||
import SwiftUI
|
||||
|
||||
struct TabBarView: View {
|
||||
struct QuickTerminalTabBarView: View {
|
||||
@ObservedObject var tabManager: QuickTerminalTabManager
|
||||
@GestureState private var isDragging: Bool = false
|
||||
|
||||
@ -9,7 +9,7 @@ struct TabBarView: View {
|
||||
ScrollView(.horizontal, showsIndicators: false) {
|
||||
HStack(spacing: 0) {
|
||||
ForEach(tabManager.tabs) { tab in
|
||||
TabItemView(
|
||||
QuickTerminalTabItemView(
|
||||
tab: tab,
|
||||
isSelected: tab.isActive,
|
||||
onSelect: { tabManager.selectTab(tab) },
|
||||
@ -21,7 +21,7 @@ struct TabBarView: View {
|
||||
}
|
||||
.onDrop(
|
||||
of: [.text],
|
||||
delegate: TabDropDelegate(
|
||||
delegate: QuickTerminalTabDropDelegate(
|
||||
item: tab,
|
||||
tabManager: tabManager,
|
||||
currentTab: tabManager.draggedTab
|
||||
@ -55,7 +55,7 @@ struct TabBarView: View {
|
||||
}
|
||||
}
|
||||
|
||||
struct TabDropDelegate: DropDelegate {
|
||||
struct QuickTerminalTabDropDelegate: DropDelegate {
|
||||
let item: QuickTerminalTab
|
||||
let tabManager: QuickTerminalTabManager
|
||||
let currentTab: QuickTerminalTab?
|
||||
|
@ -1,6 +1,6 @@
|
||||
import SwiftUI
|
||||
|
||||
struct TabItemView: View {
|
||||
struct QuickTerminalTabItemView: View {
|
||||
@ObservedObject var tab: QuickTerminalTab
|
||||
let isSelected: Bool
|
||||
let onSelect: () -> Void
|
||||
|
Reference in New Issue
Block a user