mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
[flutter]: delete conflict files
This commit is contained in:
parent
5076a6cb38
commit
9474f1f722
@ -1,4 +0,0 @@
|
||||
#import <Flutter/Flutter.h>
|
||||
|
||||
@interface FlowyInfraUIPlugin : NSObject<FlutterPlugin>
|
||||
@end
|
@ -1,15 +0,0 @@
|
||||
#import "FlowyInfraUIPlugin.h"
|
||||
#if __has_include(<flowy_infra_ui/flowy_infra_ui-Swift.h>)
|
||||
#import <flowy_infra_ui/flowy_infra_ui-Swift.h>
|
||||
#else
|
||||
// Support project import fallback if the generated compatibility header
|
||||
// is not copied when this plugin is created as a library.
|
||||
// https://forums.swift.org/t/swift-static-libraries-dont-copy-generated-objective-c-header/19816
|
||||
#import "flowy_infra_ui-Swift.h"
|
||||
#endif
|
||||
|
||||
@implementation FlowyInfraUIPlugin
|
||||
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
|
||||
[SwiftFlowyInfraUIPlugin registerWithRegistrar:registrar];
|
||||
}
|
||||
@end
|
@ -1,4 +0,0 @@
|
||||
#import <Flutter/Flutter.h>
|
||||
|
||||
@interface FlowyInfraUiPlugin : NSObject<FlutterPlugin>
|
||||
@end
|
@ -1,15 +0,0 @@
|
||||
#import "FlowyInfraUiPlugin.h"
|
||||
#if __has_include(<flowy_infra_ui/flowy_infra_ui-Swift.h>)
|
||||
#import <flowy_infra_ui/flowy_infra_ui-Swift.h>
|
||||
#else
|
||||
// Support project import fallback if the generated compatibility header
|
||||
// is not copied when this plugin is created as a library.
|
||||
// https://forums.swift.org/t/swift-static-libraries-dont-copy-generated-objective-c-header/19816
|
||||
#import "flowy_infra_ui-Swift.h"
|
||||
#endif
|
||||
|
||||
@implementation FlowyInfraUiPlugin
|
||||
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
|
||||
[SwiftFlowyInfraUiPlugin registerWithRegistrar:registrar];
|
||||
}
|
||||
@end
|
@ -1,38 +0,0 @@
|
||||
import Flutter
|
||||
import UIKit
|
||||
|
||||
public class SwiftFlowyInfraUIPlugin: NSObject, FlutterPlugin {
|
||||
|
||||
enum Constant {
|
||||
static let infraUIMethodChannelName = "flowy_infra_ui_method"
|
||||
static let infraUIKeyboardEventChannelName = "flowy_infra_ui_event/keyboard"
|
||||
|
||||
static let infraUIMethodGetPlatformVersion = "getPlatformVersion"
|
||||
}
|
||||
|
||||
public static func register(with registrar: FlutterPluginRegistrar) {
|
||||
let instance = SwiftFlowyInfraUIPlugin()
|
||||
|
||||
let methodChannel = FlutterMethodChannel(
|
||||
name: Constant.infraUIMethodChannelName,
|
||||
binaryMessenger: registrar.messenger())
|
||||
registrar.addMethodCallDelegate(instance, channel: methodChannel)
|
||||
|
||||
let keyboardEventChannel = FlutterEventChannel(
|
||||
name: Constant.infraUIKeyboardEventChannelName,
|
||||
binaryMessenger: registrar.messenger())
|
||||
keyboardEventChannel.setStreamHandler(KeyboardEventHandler())
|
||||
}
|
||||
|
||||
// MARK: - Method Channel
|
||||
|
||||
public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
|
||||
switch call.method {
|
||||
case Constant.infraUIMethodGetPlatformVersion:
|
||||
result("iOS " + UIDevice.current.systemVersion)
|
||||
default:
|
||||
result(FlutterMethodNotImplemented)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
import Flutter
|
||||
import UIKit
|
||||
|
||||
public class SwiftFlowyInfraUiPlugin: NSObject, FlutterPlugin {
|
||||
public static func register(with registrar: FlutterPluginRegistrar) {
|
||||
let channel = FlutterMethodChannel(name: "flowy_infra_ui", binaryMessenger: registrar.messenger())
|
||||
let instance = SwiftFlowyInfraUiPlugin()
|
||||
registrar.addMethodCallDelegate(instance, channel: channel)
|
||||
}
|
||||
|
||||
public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
|
||||
result("iOS " + UIDevice.current.systemVersion)
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user