To run the example project, clone the repo, and run pod install
from the Example directory first.
BTTransition is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'BTTransition'
@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
@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
biostome, 453816118@qq.com
BTTransition is available under the MIT license. See the LICENSE file for more info.