mirror of
https://github.com/wgh136/flutter_qjs.git
synced 2025-09-27 21:37:24 +00:00
15 lines
516 B
Swift
15 lines
516 B
Swift
import Flutter
|
|
import UIKit
|
|
|
|
public class SwiftFlutterQjsPlugin: NSObject, FlutterPlugin {
|
|
public static func register(with registrar: FlutterPluginRegistrar) {
|
|
let channel = FlutterMethodChannel(name: "flutter_qjs", binaryMessenger: registrar.messenger())
|
|
let instance = SwiftFlutterQjsPlugin()
|
|
registrar.addMethodCallDelegate(instance, channel: channel)
|
|
}
|
|
|
|
public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
|
|
result("iOS " + UIDevice.current.systemVersion)
|
|
}
|
|
}
|