Commit 066e4741 authored by Jidong Chen's avatar Jidong Chen

code style opt

parent 0a4d2767
...@@ -35,7 +35,6 @@ ...@@ -35,7 +35,6 @@
#define FLUTTER_VIEW FLUTTER_APP.flutterViewController.view #define FLUTTER_VIEW FLUTTER_APP.flutterViewController.view
#define FLUTTER_VC FLUTTER_APP.flutterViewController #define FLUTTER_VC FLUTTER_APP.flutterViewController
@interface FLBFlutterViewContainer () @interface FLBFlutterViewContainer ()
@property (nonatomic,copy,readwrite) NSString *name; @property (nonatomic,copy,readwrite) NSString *name;
@property (nonatomic,strong,readwrite) NSDictionary *params; @property (nonatomic,strong,readwrite) NSDictionary *params;
......
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLB2Factory : NSObject<FLBAbstractFactory> @interface FLB2Factory : NSObject<FLBAbstractFactory>
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -33,5 +33,4 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -33,5 +33,4 @@ NS_ASSUME_NONNULL_BEGIN
@interface FLB2FlutterApplication : NSObject<FLBFlutterApplicationInterface> @interface FLB2FlutterApplication : NSObject<FLBFlutterApplicationInterface>
@property (nonatomic,strong) id<FLB2Platform> platform; @property (nonatomic,strong) id<FLB2Platform> platform;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -26,8 +26,6 @@ ...@@ -26,8 +26,6 @@
#import "FLB2FlutterProvider.h" #import "FLB2FlutterProvider.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLB2FlutterEngine : NSObject<FLB2FlutterProvider> @interface FLB2FlutterEngine : NSObject<FLB2FlutterProvider>
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -27,11 +27,7 @@ ...@@ -27,11 +27,7 @@
#import "FLBFlutterContainer.h" #import "FLBFlutterContainer.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLB2FlutterViewContainer : FlutterViewController<FLBFlutterContainer> @interface FLB2FlutterViewContainer : FlutterViewController<FLBFlutterContainer>
- (void)surfaceUpdated:(BOOL)appeared; - (void)surfaceUpdated:(BOOL)appeared;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -29,15 +29,11 @@ ...@@ -29,15 +29,11 @@
@class FlutterEngine; @class FlutterEngine;
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLB2FlutterProvider <FLBFlutterViewProvider> @protocol FLB2FlutterProvider <FLBFlutterViewProvider>
@required @required
- (FlutterEngine *)engine; - (FlutterEngine *)engine;
- (void)atacheToViewController:(FlutterViewController *)vc; - (void)atacheToViewController:(FlutterViewController *)vc;
- (void)detach; - (void)detach;
- (void)prepareEngineIfNeeded; - (void)prepareEngineIfNeeded;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -26,9 +26,7 @@ ...@@ -26,9 +26,7 @@
#import "FLBPlatform.h" #import "FLBPlatform.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLB2Platform <FLBPlatform> @protocol FLB2Platform <FLBPlatform>
@optional @optional
- (BOOL)useBoost2; - (BOOL)useBoost2;
...@@ -43,5 +41,4 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -43,5 +41,4 @@ NS_ASSUME_NONNULL_BEGIN
exts:(NSDictionary *)exts exts:(NSDictionary *)exts
completion:(void (^)(BOOL finished))completion; completion:(void (^)(BOOL finished))completion;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -30,13 +30,9 @@ ...@@ -30,13 +30,9 @@
#import "FLBFlutterContainer.h" #import "FLBFlutterContainer.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLBAbstractFactory <NSObject> @protocol FLBAbstractFactory <NSObject>
@required @required
- (id<FLBFlutterApplicationInterface>)createApplication:(id<FLB2Platform>)platform; - (id<FLBFlutterApplicationInterface>)createApplication:(id<FLB2Platform>)platform;
- (id<FLBFlutterContainer>)createFlutterContainer; - (id<FLBFlutterContainer>)createFlutterContainer;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -25,12 +25,9 @@ ...@@ -25,12 +25,9 @@
#import <Flutter/Flutter.h> #import <Flutter/Flutter.h>
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLBFlutterAppDelegate : FlutterAppDelegate @interface FLBFlutterAppDelegate : FlutterAppDelegate
// Returns the key window's rootViewController, if it's a FlutterViewController. // Returns the key window's rootViewController, if it's a FlutterViewController.
// Otherwise, returns nil. // Otherwise, returns nil.
- (FlutterViewController*)rootFlutterViewController; - (FlutterViewController*)rootFlutterViewController;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -31,5 +31,4 @@ ...@@ -31,5 +31,4 @@
- (FlutterViewController*)rootFlutterViewController { - (FlutterViewController*)rootFlutterViewController {
return FlutterBoostPlugin.sharedInstance.application.flutterViewController; return FlutterBoostPlugin.sharedInstance.application.flutterViewController;
} }
@end @end
...@@ -21,7 +21,6 @@ ...@@ -21,7 +21,6 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE. * THE SOFTWARE.
*/ */
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#import <Flutter/Flutter.h> #import <Flutter/Flutter.h>
#import "FLB2Platform.h" #import "FLB2Platform.h"
...@@ -29,10 +28,8 @@ ...@@ -29,10 +28,8 @@
#import "FLB2FlutterProvider.h" #import "FLB2FlutterProvider.h"
#import "FLBFlutterContainer.h" #import "FLBFlutterContainer.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLBFlutterApplicationInterface <NSObject> @protocol FLBFlutterApplicationInterface <NSObject>
@property (nonatomic,strong) id<FLB2Platform> platform; @property (nonatomic,strong) id<FLB2Platform> platform;
- (id<FLB2FlutterProvider>)flutterProvider; - (id<FLB2FlutterProvider>)flutterProvider;
...@@ -57,7 +54,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -57,7 +54,6 @@ NS_ASSUME_NONNULL_BEGIN
- (BOOL)isRunning; - (BOOL)isRunning;
#pragma mark - handle messages #pragma mark - handle messages
- (void)close:(NSString *)uid - (void)close:(NSString *)uid
result:(NSDictionary *)result result:(NSDictionary *)result
exts:(NSDictionary *)exts exts:(NSDictionary *)exts
...@@ -79,7 +75,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -79,7 +75,6 @@ NS_ASSUME_NONNULL_BEGIN
uniqueId:(NSString *)uniqueId; uniqueId:(NSString *)uniqueId;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -26,12 +26,10 @@ ...@@ -26,12 +26,10 @@
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLBFlutterContainer <NSObject> @protocol FLBFlutterContainer <NSObject>
- (NSString *)name; - (NSString *)name;
- (NSDictionary *)params; - (NSDictionary *)params;
- (NSString *)uniqueIDString; - (NSString *)uniqueIDString;
- (void)setName:(NSString *)name params:(NSDictionary *)params; - (void)setName:(NSString *)name params:(NSDictionary *)params;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -26,7 +26,6 @@ ...@@ -26,7 +26,6 @@
#import "FLBFlutterContainer.h" #import "FLBFlutterContainer.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface FLBFlutterContainerManager : NSObject @interface FLBFlutterContainerManager : NSObject
- (NSString *)peak; - (NSString *)peak;
...@@ -35,5 +34,4 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -35,5 +34,4 @@ NS_ASSUME_NONNULL_BEGIN
- (BOOL)contains:(id<FLBFlutterContainer>)vc; - (BOOL)contains:(id<FLBFlutterContainer>)vc;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -25,7 +25,6 @@ ...@@ -25,7 +25,6 @@
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@protocol FLBPlatform <NSObject> @protocol FLBPlatform <NSObject>
@required @required
...@@ -39,5 +38,4 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -39,5 +38,4 @@ NS_ASSUME_NONNULL_BEGIN
params:(NSDictionary *)params params:(NSDictionary *)params
completion:(void (^)(BOOL finished))completion; completion:(void (^)(BOOL finished))completion;
@end @end
NS_ASSUME_NONNULL_END NS_ASSUME_NONNULL_END
...@@ -27,16 +27,17 @@ ...@@ -27,16 +27,17 @@
#import "FLBTypes.h" #import "FLBTypes.h"
@interface FlutterBoostPlugin : NSObject<FlutterPlugin> @interface FlutterBoostPlugin : NSObject<FlutterPlugin>
#pragma mark - Initializer #pragma mark - Initializer
+ (instancetype)sharedInstance; + (instancetype)sharedInstance;
- (void)startFlutterWithPlatform:(id<FLB2Platform>)platform - (void)startFlutterWithPlatform:(id<FLB2Platform>)platform
onStart:(void (^)(id<FlutterBinaryMessenger, FlutterTextureRegistry, FlutterPluginRegistry> engine))callback; onStart:(void (^)(id<FlutterBinaryMessenger,
FlutterTextureRegistry,
FlutterPluginRegistry> engine))callback;
#pragma mark - Some properties. #pragma mark - Some properties.
- (BOOL)isRunning; - (BOOL)isRunning;
- (FlutterViewController *)currentViewController; - (FlutterViewController *)currentViewController;
#pragma mark - broadcast event to/from flutter #pragma mark - broadcast event to/from flutter
...@@ -45,5 +46,4 @@ ...@@ -45,5 +46,4 @@
- (FLBVoidCallback)addEventListener:(FLBEventListener)listner - (FLBVoidCallback)addEventListener:(FLBEventListener)listner
forName:(NSString *)name; forName:(NSString *)name;
@end @end
...@@ -30,13 +30,10 @@ ...@@ -30,13 +30,10 @@
id<FLBFlutterApplicationInterface> _application; id<FLBFlutterApplicationInterface> _application;
id<FLBAbstractFactory> _factory; id<FLBAbstractFactory> _factory;
} }
- (id<FLBFlutterApplicationInterface>)application;
- (id<FLBAbstractFactory>)factory;
@property (nonatomic,strong) FlutterMethodChannel *methodChannel; @property (nonatomic,strong) FlutterMethodChannel *methodChannel;
@property (nonatomic,copy) NSString *fPageId; @property (nonatomic,copy) NSString *fPageId;
@property (nonatomic,copy) NSString *fPagename; @property (nonatomic,copy) NSString *fPagename;
@property (nonatomic,strong) NSDictionary *fParams; @property (nonatomic,strong) NSDictionary *fParams;
- (id<FLBFlutterApplicationInterface>)application;
- (id<FLBAbstractFactory>)factory;
@end @end
...@@ -21,12 +21,9 @@ ...@@ -21,12 +21,9 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE. * THE SOFTWARE.
*/ */
#import "BoostMessageChannel.h" #import "BoostMessageChannel.h"
#import "FlutterBoostPlugin_private.h" #import "FlutterBoostPlugin_private.h"
@implementation BoostMessageChannel @implementation BoostMessageChannel
+ (NSMutableDictionary *)lists{ + (NSMutableDictionary *)lists{
......
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