This commit is contained in:
agra
2026-04-22 22:42:53 +03:00
parent 2113537078
commit 7e0b9a6330
17 changed files with 552 additions and 19 deletions

View File

@@ -0,0 +1,18 @@
import FlutterMacOS
import AppKit
public protocol NativePlugin {
func register(with registrar: FlutterPluginRegistrar)
}
public enum UxWindow {
public static var keyWindow: NSWindow? {
NSApp.keyWindow ?? NSApp.mainWindow
}
/// FlutterViewController's view. Used as the anchor for
/// `NSSharingServicePicker` popovers.
public static var flutterView: NSView? {
keyWindow?.contentViewController?.view
}
}