Commit b5ef7160 authored by Jidong Chen's avatar Jidong Chen

almost done

parent 5173dd21
...@@ -126,10 +126,5 @@ ...@@ -126,10 +126,5 @@
[self.viewProvider inactive]; [self.viewProvider inactive];
} }
- (void)setAccessibilityEnable:(BOOL)enable
{
[self.viewProvider setAccessibilityEnable:enable];
}
@end @end
...@@ -47,11 +47,6 @@ ...@@ -47,11 +47,6 @@
method_exchangeImplementations(originalMethod, swizzledMethod); method_exchangeImplementations(originalMethod, swizzledMethod);
_viewController = [FLBFlutterViewControllerAdaptor new]; _viewController = [FLBFlutterViewControllerAdaptor new];
if([platform respondsToSelector:@selector(accessibilityEnable)]){
_viewController.accessibilityEnable = [platform accessibilityEnable];
}else{
_viewController.accessibilityEnable = YES;
}
[_viewController view]; [_viewController view];
Class clazz = NSClassFromString(@"GeneratedPluginRegistrant"); Class clazz = NSClassFromString(@"GeneratedPluginRegistrant");
......
...@@ -25,21 +25,20 @@ ...@@ -25,21 +25,20 @@
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
@class FlutterViewController; @class FlutterViewController;
@class FlutterEngine;
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
#define RELEASE_1_0 1 #define RELEASE_1_0 0
@protocol FLBFlutterProvider <NSObject> @protocol FLBFlutterViewProvider <NSObject>
@required @required
- (FlutterViewController *)viewController;
- (void)pause; - (void)pause;
- (void)resume; - (void)resume;
- (void)inactive; - (void)inactive;
- (void)prepareEngineIfNeeded;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -29,10 +29,12 @@ ...@@ -29,10 +29,12 @@
#import "FLBMemoryInspector.h" #import "FLBMemoryInspector.h"
#import "Service_NavigationService.h" #import "Service_NavigationService.h"
#import "FlutterBoostConfig.h" #import "FlutterBoostConfig.h"
#import "FlutterBoostPlugin_private.h"
#define FLUTTER_APP [FlutterBoostPlugin sharedInstance].application
#define FLUTTER_VIEW FLUTTER_APP.flutterViewController.view
#define FLUTTER_VC FLUTTER_APP.flutterViewController
#define FLUTTER_VIEW [FLBFlutterApplication sharedApplication].flutterViewController.view
#define FLUTTER_VC [FLBFlutterApplication sharedApplication].flutterViewController
#define FLUTTER_APP [FLBFlutterApplication sharedApplication]
@interface FLBFlutterViewContainer () @interface FLBFlutterViewContainer ()
@property (nonatomic,copy,readwrite) NSString *name; @property (nonatomic,copy,readwrite) NSString *name;
...@@ -77,7 +79,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -77,7 +79,7 @@ static NSUInteger kInstanceCounter = 0;
kInstanceCounter--; kInstanceCounter--;
if([self.class instanceCounter] == 0){ if([self.class instanceCounter] == 0){
[[FLBStackCache sharedInstance] clear]; [[FLBStackCache sharedInstance] clear];
[[FLBFlutterApplication sharedApplication] pause]; [FLUTTER_APP pause];
} }
} }
...@@ -143,7 +145,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -143,7 +145,7 @@ static NSUInteger kInstanceCounter = 0;
uniqueId:[self uniqueIDString]]; uniqueId:[self uniqueIDString]];
[[FLBStackCache sharedInstance] remove:self.uniqueIDString]; [[FLBStackCache sharedInstance] remove:self.uniqueIDString];
[[FLBFlutterApplication sharedApplication] removeViewController:self]; [FLUTTER_APP removeViewController:self];
[self.class instanceCounterDecrease]; [self.class instanceCounterDecrease];
} }
...@@ -290,7 +292,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -290,7 +292,7 @@ static NSUInteger kInstanceCounter = 0;
- (void)viewDidLayoutSubviews - (void)viewDidLayoutSubviews
{ {
[super viewDidLayoutSubviews]; [super viewDidLayoutSubviews];
[[FLBFlutterApplication sharedApplication] resume]; [FLUTTER_APP resume];
} }
- (void)viewWillAppear:(BOOL)animated - (void)viewWillAppear:(BOOL)animated
...@@ -299,10 +301,10 @@ static NSUInteger kInstanceCounter = 0; ...@@ -299,10 +301,10 @@ static NSUInteger kInstanceCounter = 0;
self.interactiveGestureActive = true; self.interactiveGestureActive = true;
} }
[[FLBFlutterApplication sharedApplication] resume]; [FLUTTER_APP resume];
//For new page we should attach flutter view in view will appear //For new page we should attach flutter view in view will appear
//for better performance. //for better performance.
if(![[FLBFlutterApplication sharedApplication] contains:self]){ if(![FLUTTER_APP contains:self]){
[self attatchFlutterView]; [self attatchFlutterView];
} }
...@@ -313,10 +315,10 @@ static NSUInteger kInstanceCounter = 0; ...@@ -313,10 +315,10 @@ static NSUInteger kInstanceCounter = 0;
params:_params params:_params
uniqueId:self.uniqueIDString]; uniqueId:self.uniqueIDString];
//Save some first time page info. //Save some first time page info.
if(![FlutterBoostConfig sharedInstance].fPagename){ if(![FlutterBoostPlugin sharedInstance].fPagename){
[FlutterBoostConfig sharedInstance].fPagename = _name; [FlutterBoostPlugin sharedInstance].fPagename = _name;
[FlutterBoostConfig sharedInstance].fPageId = self.uniqueIDString; [FlutterBoostPlugin sharedInstance].fPageId = self.uniqueIDString;
[FlutterBoostConfig sharedInstance].fParams = _params; [FlutterBoostPlugin sharedInstance].fParams = _params;
} }
[super viewWillAppear:animated]; [super viewWillAppear:animated];
...@@ -324,7 +326,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -324,7 +326,7 @@ static NSUInteger kInstanceCounter = 0;
- (void)viewDidAppear:(BOOL)animated - (void)viewDidAppear:(BOOL)animated
{ {
[[FLBFlutterApplication sharedApplication] resume]; [FLUTTER_APP resume];
//Ensure flutter view is attached. //Ensure flutter view is attached.
[self attatchFlutterView]; [self attatchFlutterView];
...@@ -334,7 +336,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -334,7 +336,7 @@ static NSUInteger kInstanceCounter = 0;
params:_params params:_params
uniqueId:self.uniqueIDString]; uniqueId:self.uniqueIDString];
[[FLBFlutterApplication sharedApplication] addUniqueViewController:self]; [FLUTTER_APP addUniqueViewController:self];
[super viewDidAppear:animated]; [super viewDidAppear:animated];
......
...@@ -32,7 +32,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -32,7 +32,6 @@ NS_ASSUME_NONNULL_BEGIN
- (void)boost_viewWillDisappear:(BOOL)animated; - (void)boost_viewWillDisappear:(BOOL)animated;
- (void)boost_viewDidDisappear:(BOOL)animated; - (void)boost_viewDidDisappear:(BOOL)animated;
@property (nonatomic,assign) BOOL accessibilityEnable;
@end @end
......
...@@ -95,11 +95,5 @@ ...@@ -95,11 +95,5 @@
//Override this to avoid unnecessary splash Screen. //Override this to avoid unnecessary splash Screen.
} }
- (void)fixed_onAccessibilityStatusChanged:(NSNotification*)notification {
if(self.accessibilityEnable){
[self fixed_onAccessibilityStatusChanged:notification];
}
}
@end @end
...@@ -33,8 +33,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -33,8 +33,6 @@ NS_ASSUME_NONNULL_BEGIN
@protocol FLBFlutterViewProvider <NSObject> @protocol FLBFlutterViewProvider <NSObject>
@required @required
- (void)setAccessibilityEnable:(BOOL)enable;
- (BOOL)accessibilityEnable;
- (FlutterViewController *)viewController; - (FlutterViewController *)viewController;
- (void)pause; - (void)pause;
- (void)resume; - (void)resume;
......
...@@ -23,7 +23,6 @@ ...@@ -23,7 +23,6 @@
*/ */
#import "FLBViewProviderFactory.h" #import "FLBViewProviderFactory.h"
#import "FLBFlutterEngine.h"
#import "FLBFlutterEngineOld.h" #import "FLBFlutterEngineOld.h"
#import "FLBPlatform.h" #import "FLBPlatform.h"
......
...@@ -23,10 +23,11 @@ ...@@ -23,10 +23,11 @@
*/ */
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#import "FLBAbstractFactory.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLB2Factory : NSObject @interface FLB2Factory : NSObject<FLBAbstractFactory>
@end @end
......
// /*
// FLBFactory.m * The MIT License (MIT)
// flutter_boost *
// * Copyright (c) 2019 Alibaba Group
// Created by Jidong Chen on 2019/6/11. *
// * Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#import "FLB2Factory.h" #import "FLB2Factory.h"
#import "FLB2FlutterApplication.h"
#import "FLB2FlutterViewContainer.h"
@implementation FLB2Factory @implementation FLB2Factory
- (id<FLBFlutterApplicationInterface>)createApplication:(id<FLB2Platform>)platform
{
return FLB2FlutterApplication.new;
}
- (id<FLBFlutterContainer>)createFlutterContainer
{
return FLB2FlutterViewContainer.new;
}
@end @end
...@@ -32,27 +32,6 @@ ...@@ -32,27 +32,6 @@
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLB2FlutterApplication : NSObject<FLBFlutterApplicationInterface> @interface FLB2FlutterApplication : NSObject<FLBFlutterApplicationInterface>
@property (nonatomic,strong) id<FLB2Platform> platform;
- (id<FLB2FlutterProvider>)flutterProvider;
#pragma mark - Getters
+ (FLB2FlutterApplication *)sharedApplication;
- (void)startFlutterWithPlatform:(id<FLB2Platform>)platform
onStart:(void (^)(FlutterEngine * _Nonnull))callback;
- (FlutterViewController *)flutterViewController;
#pragma mark - Container Management
- (BOOL)contains:(FLB2FlutterViewContainer *)vc;
- (void)addUniqueViewController:(FLB2FlutterViewContainer *)vc;
- (void)removeViewController:(FLB2FlutterViewContainer *)vc;
- (BOOL)isTop:(NSString *)pageId;
#pragma mark - App Control
- (void)pause;
- (void)resume;
- (void)inactive;
- (BOOL)isRunning;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -30,7 +30,6 @@ ...@@ -30,7 +30,6 @@
@property (nonatomic,strong) FLBFlutterContainerManager *manager; @property (nonatomic,strong) FLBFlutterContainerManager *manager;
@property (nonatomic,strong) id<FLB2FlutterProvider> viewProvider; @property (nonatomic,strong) id<FLB2FlutterProvider> viewProvider;
@property (nonatomic,strong) NSMutableDictionary *pageBuilders;
@property (nonatomic,assign) BOOL isRunning; @property (nonatomic,assign) BOOL isRunning;
@end @end
...@@ -58,7 +57,7 @@ ...@@ -58,7 +57,7 @@
} }
- (void)startFlutterWithPlatform:(id<FLB2Platform>)platform - (void)startFlutterWithPlatform:(id<FLB2Platform>)platform
onStart:(void (^)(FlutterEngine * _Nonnull))callback onStart:(void (^)(id<FlutterBinaryMessenger,FlutterTextureRegistry,FlutterPluginRegistry> _Nonnull))callback
{ {
static dispatch_once_t onceToken; static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{ dispatch_once(&onceToken, ^{
...@@ -73,7 +72,6 @@ ...@@ -73,7 +72,6 @@
{ {
if (self = [super init]) { if (self = [super init]) {
_manager = [FLBFlutterContainerManager new]; _manager = [FLBFlutterContainerManager new];
_pageBuilders = [NSMutableDictionary new];
} }
return self; return self;
} }
...@@ -89,17 +87,17 @@ ...@@ -89,17 +87,17 @@
} }
- (BOOL)contains:(FLB2FlutterViewContainer *)vc - (BOOL)contains:(id<FLBFlutterContainer>)vc
{ {
return [_manager contains:vc]; return [_manager contains:vc];
} }
- (void)addUniqueViewController:(FLB2FlutterViewContainer *)vc - (void)addUniqueViewController:(id<FLBFlutterContainer>)vc
{ {
return [_manager addUnique:vc]; return [_manager addUnique:vc];
} }
- (void)removeViewController:(FLB2FlutterViewContainer *)vc - (void)removeViewController:(id<FLBFlutterContainer>)vc
{ {
return [_manager remove:vc]; return [_manager remove:vc];
} }
......
...@@ -28,9 +28,9 @@ ...@@ -28,9 +28,9 @@
#import "FLBFlutterContainerManager.h" #import "FLBFlutterContainerManager.h"
#import "FlutterBoostPlugin_private.h" #import "FlutterBoostPlugin_private.h"
#define FLUTTER_VIEW [FLB2FlutterApplication sharedApplication].flutterViewController.view #define FLUTTER_APP [FlutterBoostPlugin sharedInstance].application
#define FLUTTER_VC [FLB2FlutterApplication sharedApplication].flutterViewController #define FLUTTER_VIEW FLUTTER_APP.flutterViewController.view
#define FLUTTER_APP [FLB2FlutterApplication sharedApplication] #define FLUTTER_VC FLUTTER_APP.flutterViewController
@interface FLB2FlutterViewContainer () @interface FLB2FlutterViewContainer ()
@property (nonatomic,copy,readwrite) NSString *name; @property (nonatomic,copy,readwrite) NSString *name;
...@@ -91,7 +91,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -91,7 +91,7 @@ static NSUInteger kInstanceCounter = 0;
{ {
kInstanceCounter--; kInstanceCounter--;
if([self.class instanceCounter] == 0){ if([self.class instanceCounter] == 0){
// [[FLBFlutterApplication sharedApplication] pause]; // [FLUTTER_APP pause];
} }
} }
...@@ -119,7 +119,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -119,7 +119,7 @@ static NSUInteger kInstanceCounter = 0;
pageName:_name params:_params pageName:_name params:_params
uniqueId:[self uniqueIDString]]; uniqueId:[self uniqueIDString]];
[[FLB2FlutterApplication sharedApplication] removeViewController:self]; [FLUTTER_APP removeViewController:self];
[self.class instanceCounterDecrease]; [self.class instanceCounterDecrease];
} }
...@@ -152,7 +152,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -152,7 +152,7 @@ static NSUInteger kInstanceCounter = 0;
- (void)viewDidLayoutSubviews - (void)viewDidLayoutSubviews
{ {
[super viewDidLayoutSubviews]; [super viewDidLayoutSubviews];
[[FLB2FlutterApplication sharedApplication] resume]; [FLUTTER_APP resume];
} }
- (void)viewWillAppear:(BOOL)animated - (void)viewWillAppear:(BOOL)animated
...@@ -163,7 +163,7 @@ static NSUInteger kInstanceCounter = 0; ...@@ -163,7 +163,7 @@ static NSUInteger kInstanceCounter = 0;
[self attatchFlutterEngine]; [self attatchFlutterEngine];
} }
[[FLB2FlutterApplication sharedApplication] resume]; [FLUTTER_APP resume];
[self surfaceUpdated:YES]; [self surfaceUpdated:YES];
//For new page we should attach flutter view in view will appear //For new page we should attach flutter view in view will appear
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
*/ */
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#import "FLBFlutterProvider.h" #import "FLBFlutterViewProvider.h"
@class FlutterViewController; @class FlutterViewController;
@class FlutterEngine; @class FlutterEngine;
...@@ -32,16 +32,12 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -32,16 +32,12 @@ NS_ASSUME_NONNULL_BEGIN
#define RELEASE_1_0 1 #define RELEASE_1_0 1
@protocol FLB2FlutterProvider <FLBFlutterProvider> @protocol FLB2FlutterProvider <FLBFlutterViewProvider>
@required @required
- (FlutterEngine *)engine; - (FlutterEngine *)engine;
- (void)atacheToViewController:(FlutterViewController *)vc; - (void)atacheToViewController:(FlutterViewController *)vc;
- (void)detach; - (void)detach;
- (void)pause;
- (void)resume;
- (void)inactive;
- (void)prepareEngineIfNeeded; - (void)prepareEngineIfNeeded;
@end @end
......
...@@ -30,8 +30,7 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -30,8 +30,7 @@ NS_ASSUME_NONNULL_BEGIN
@protocol FLB2Platform <FLBPlatform> @protocol FLB2Platform <FLBPlatform>
@optional @optional
//Whether to enable accessibility support. Default value is Yes. - (BOOL)userBoost2;
- (BOOL)accessibilityEnable;
@required @required
- (void)openPage:(NSString *)name - (void)openPage:(NSString *)name
......
// /*
// FLBFlutterContainer.h * The MIT License (MIT)
// flutter_boost *
// * Copyright (c) 2019 Alibaba Group
// Created by Jidong Chen on 2019/6/11. *
// * Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
......
...@@ -28,10 +28,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -28,10 +28,6 @@ NS_ASSUME_NONNULL_BEGIN
@protocol FLBPlatform <NSObject> @protocol FLBPlatform <NSObject>
@optional
//Whether to enable accessibility support. Default value is Yes.
- (BOOL)accessibilityEnable;
@required @required
- (void)openPage:(NSString *)name - (void)openPage:(NSString *)name
params:(NSDictionary *)params params:(NSDictionary *)params
......
...@@ -25,6 +25,8 @@ ...@@ -25,6 +25,8 @@
#import "FlutterBoostPlugin.h" #import "FlutterBoostPlugin.h"
#import "FLBResultMediator.h" #import "FLBResultMediator.h"
#import "FlutterBoostPlugin_private.h" #import "FlutterBoostPlugin_private.h"
#import "FLBFactory.h"
#import "FLB2Factory.h"
@implementation FlutterBoostPlugin @implementation FlutterBoostPlugin
...@@ -70,9 +72,18 @@ ...@@ -70,9 +72,18 @@
FlutterTextureRegistry, FlutterTextureRegistry,
FlutterPluginRegistry> engine))callback; FlutterPluginRegistry> engine))callback;
{ {
//TODO: static dispatch_once_t onceToken;
[self.application startFlutterWithPlatform:platform dispatch_once(&onceToken, ^{
onStart:callback];
if([platform respondsToSelector:@selector(userBoost2)] && platform.userBoost2){
_factory = FLB2Factory.new;
}else{
_factory = FLBFactory.new;
}
_application = [_factory createApplication:platform];
[_application startFlutterWithPlatform:platform onStart:callback];
});
} }
- (BOOL)isRunning - (BOOL)isRunning
......
...@@ -27,12 +27,15 @@ ...@@ -27,12 +27,15 @@
#import "FLBResultMediator.h" #import "FLBResultMediator.h"
#import "FLBAbstractFactory.h" #import "FLBAbstractFactory.h"
@interface FlutterBoostPlugin() @interface FlutterBoostPlugin(){
id<FLBFlutterApplicationInterface> _application;
FLBResultMediator *_resultMediator;
id<FLBAbstractFactory> _factory;
}
- (id<FLBFlutterApplicationInterface>)application; - (id<FLBFlutterApplicationInterface>)application;
- (FLBResultMediator *)resultMediator;
@property (nonatomic,strong) FLBResultMediator *resultMediator; - (id<FLBAbstractFactory>)factory;
@property (nonatomic,strong) id<FLBAbstractFactory> factory;
@property (nonatomic,copy) NSString *fPageId; @property (nonatomic,copy) NSString *fPageId;
@property (nonatomic,copy) NSString *fPagename; @property (nonatomic,copy) NSString *fPagename;
......
...@@ -24,9 +24,11 @@ ...@@ -24,9 +24,11 @@
//Generated by AIOCodeGen. //Generated by AIOCodeGen.
#import "ServiceGateway.h" #import "ServiceGateway.h"
#import "NavigationService_closePage.h" #import "NavigationService_closePage.h"
#import "FLB2FlutterApplication.h" #import "FlutterBoostPlugin_private.h"
#define FLUTTER_APP [FlutterBoostPlugin sharedInstance].application
@implementation NavigationService_closePage @implementation NavigationService_closePage
...@@ -37,7 +39,7 @@ ...@@ -37,7 +39,7 @@
animated:(NSNumber *)animated animated:(NSNumber *)animated
{ {
//Add your handler code here! //Add your handler code here!
[[FLB2FlutterApplication sharedApplication].platform closePage:uniqueId [FLUTTER_APP.platform closePage:uniqueId
animated:animated.boolValue animated:animated.boolValue
params:params params:params
completion:^(BOOL finished) { completion:^(BOOL finished) {
......
...@@ -24,17 +24,18 @@ ...@@ -24,17 +24,18 @@
//Generated by AIOCodeGen. //Generated by AIOCodeGen.
#import "ServiceGateway.h" #import "ServiceGateway.h"
#import "NavigationService_openPage.h" #import "NavigationService_openPage.h"
#import "FLB2FlutterApplication.h"
#import "FlutterBoost.h"
#import "Service_NavigationService.h" #import "Service_NavigationService.h"
#import "FlutterBoostPlugin_private.h"
#define FLUTTER_APP [FlutterBoostPlugin sharedInstance].application
@implementation NavigationService_openPage @implementation NavigationService_openPage
- (void)onCall:(void (^)(BOOL))result pageName:(NSString *)pageName params:(NSDictionary *)params animated:(NSNumber *)animated - (void)onCall:(void (^)(BOOL))result pageName:(NSString *)pageName params:(NSDictionary *)params animated:(NSNumber *)animated
{ {
[[FLB2FlutterApplication sharedApplication].platform openPage:pageName [FLUTTER_APP.platform openPage:pageName
params:params params:params
animated:animated.boolValue animated:animated.boolValue
completion:^(BOOL finished) { completion:^(BOOL finished) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment