Add screenshot generator

This commit is contained in:
世界
2026-01-08 16:13:20 +08:00
parent 264c4eed81
commit 6b589cb771
57 changed files with 1931 additions and 109 deletions
-14
View File
@@ -157,20 +157,6 @@ private class WindowState {
}
}
private struct WindowAccessor: NSViewRepresentable {
let callback: (NSWindow?) -> Void
func makeNSView(context _: Context) -> NSView {
let view = NSView()
DispatchQueue.main.async {
callback(view.window)
}
return view
}
func updateNSView(_: NSView, context _: Context) {}
}
private class WindowCloseDelegate: NSObject, NSWindowDelegate {
var allowClose = false
private let windowState: WindowState