UIViewControllerDemo.m 1.29 KB
Newer Older
Jidong Chen's avatar
init  
Jidong Chen committed
1 2 3 4 5 6 7 8 9 10 11
//
//  UIViewControllerDemo.m
//  Runner
//
//  Created by Jidong Chen on 2018/10/17.
//  Copyright © 2018年 The Chromium Authors. All rights reserved.
//

#import "UIViewControllerDemo.h"
#import <Flutter/Flutter.h>
#import "DemoRouter.h"
Jidong Chen's avatar
Jidong Chen committed
12
#import <flutter_boost/FlutterBoostPlugin.h>
Jidong Chen's avatar
init  
Jidong Chen committed
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27


@interface UIViewControllerDemo ()

@end

@implementation UIViewControllerDemo

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
}


- (IBAction)pushFlutterPage:(id)sender {
Jidong Chen's avatar
Jidong Chen committed
28 29 30 31 32
    [DemoRouter.sharedRouter openPage:@"first" params:@{} animated:YES completion:^(BOOL f){
        
        [FlutterBoostPlugin.sharedInstance onResultForKey:@"result_id_100" resultData:@{} params:@{}];
        
    }];
Jidong Chen's avatar
init  
Jidong Chen committed
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
}

- (IBAction)present:(id)sender {
    [DemoRouter.sharedRouter openPage:@"second" params:@{@"present":@(YES)} animated:YES completion:^(BOOL f){}];
//    [self dismissViewControllerAnimated:YES completion:completion];
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end