21 lines
605 B
Swift
21 lines
605 B
Swift
import Cocoa
|
|
import FlutterMacOS
|
|
|
|
@main
|
|
class AppDelegate: FlutterAppDelegate {
|
|
override func applicationDidFinishLaunching(_ notification: Notification) {
|
|
if let iconPath = Bundle.main.path(forResource: "AppIcon", ofType: "icns") {
|
|
NSApp.applicationIconImage = NSImage(contentsOfFile: iconPath)
|
|
}
|
|
|
|
super.applicationDidFinishLaunching(notification)
|
|
}
|
|
|
|
override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
|
|
return true
|
|
}
|
|
|
|
override func applicationSupportsSecureRestorableState(_ app: NSApplication) -> Bool {
|
|
return true
|
|
}
|
|
}
|