Check token info and update to new info

This commit is contained in:
2024-02-02 16:09:43 +08:00
parent cd31d117af
commit 6476d7bf8c
10 changed files with 141 additions and 14 deletions

View File

@@ -136,6 +136,18 @@ class MainFlutterWindow: NSWindow {
result(FlutterMethodNotImplemented)
}
}
let deviceChannel = FlutterMethodChannel(
name: "lifegpc.eh_downloader_flutter/device",
binaryMessenger: flutterViewController.engine.binaryMessenger)
deviceChannel.setMethodCallHandler { (call, result) in
switch call.method {
case "deviceName":
result(Host.current().localizedName)
default:
result(FlutterMethodNotImplemented)
}
}
RegisterGeneratedPlugins(registry: flutterViewController)