mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-10-01 23:48:35 +00:00
macos: comment the new views
This commit is contained in:
@@ -1,16 +1,21 @@
|
||||
import SwiftUI
|
||||
|
||||
/// This delegate is notified of the completion result of the paste protection dialog.
|
||||
protocol PasteProtectionViewDelegate: AnyObject {
|
||||
func pasteProtectionComplete(_ action: PasteProtectionView.Action)
|
||||
}
|
||||
|
||||
/// The SwiftUI view for showing a paste protection dialog.
|
||||
struct PasteProtectionView: View {
|
||||
enum Action : String {
|
||||
case cancel
|
||||
case paste
|
||||
}
|
||||
|
||||
/// The contents of the paste.
|
||||
let contents: String
|
||||
|
||||
/// Optional delegate to get results. If this is nil, then this view will never close on its own.
|
||||
weak var delegate: PasteProtectionViewDelegate? = nil
|
||||
|
||||
var body: some View {
|
||||
|
Reference in New Issue
Block a user