BTTransition 0.1.1

BTTransition 0.1.1

Maintained by yetongxue.



  • By
  • biostome

BTTransition

CI Status Version License Platform

Preview

展示

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

Installation

BTTransition is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'BTTransition'

Easy Usg

@implementation BTPresentViewController
- (instancetype)init{
    UIStoryboard * storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
    self = [storyboard instantiateViewControllerWithIdentifier:@"BTPresentViewController"];;
    if (self) {
        _aniamtion = [[BTCoverVerticalTransition alloc]initPresentViewController:self withRragDismissEnabal:YES];
        self.transitioningDelegate = _aniamtion;
    }
    return self;
}
...
@end

Or

@implementation BTPresentViewController
- (instancetype)init{
    [super init];
    if (self) {
        _aniamtion = [[BTCoverVerticalTransition alloc]initPresentViewController:self withRragDismissEnabal:YES];
        self.transitioningDelegate = _aniamtion;
    }
    return self;
}
...
@end

How present

@implementation


- (void)viewDidLoad {
    [super viewDidLoad];
    ...
}

- (void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event{
    BTPresentViewController * vc = [[BTPresentViewController alloc]init];;
    [self presentViewController:vc animated:YES completion:nil];
}
...
@end

Author

biostome, [email protected]

License

BTTransition is available under the MIT license. See the LICENSE file for more info.