init project
This commit is contained in:
36
ios/Classes/AMapFlutterFactory.m
Normal file
36
ios/Classes/AMapFlutterFactory.m
Normal file
@ -0,0 +1,36 @@
|
||||
//
|
||||
// AMapFlutterFactory.m
|
||||
// amap_map
|
||||
//
|
||||
// Created by lly on 2020/10/29.
|
||||
//
|
||||
|
||||
#import "AMapFlutterFactory.h"
|
||||
#import <MAMapKit/MAMapKit.h>
|
||||
#import "AMapViewController.h"
|
||||
|
||||
@implementation AMapFlutterFactory {
|
||||
NSObject<FlutterPluginRegistrar>* _registrar;
|
||||
}
|
||||
|
||||
- (instancetype)initWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
|
||||
self = [super init];
|
||||
if (self) {
|
||||
_registrar = registrar;
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
- (NSObject<FlutterMessageCodec>*)createArgsCodec {
|
||||
return [FlutterStandardMessageCodec sharedInstance];
|
||||
}
|
||||
|
||||
- (NSObject<FlutterPlatformView>*)createWithFrame:(CGRect)frame
|
||||
viewIdentifier:(int64_t)viewId
|
||||
arguments:(id _Nullable)args {
|
||||
return [[AMapViewController alloc] initWithFrame:frame
|
||||
viewIdentifier:viewId
|
||||
arguments:args
|
||||
registrar:_registrar];
|
||||
}
|
||||
@end
|
Reference in New Issue
Block a user