嗨,我正在尝试创建一个自定义模式segue,将src视图控制器向右滑动,显示其后面的目标视图控制器。关于我如何实现它的任何想法
到目前为止,我已经尝试了这个,但它没有用。
#import "CustomMenuSegue.h"
@implementation CustomMenuSegue
- (void) perform {
UIViewController *src = (UIViewController *) self.sourceViewController;
UIViewController *dst = (UIViewController *) self.destinationViewController;
[UIView transitionWithView:src.navigationController.view duration:0.2 options:UIUserInterfaceLayoutDirectionRightToLeft
animations:^{
[src.navigationController modalTransitionStyle:dst animated:YES];
}
completion:NULL];
}
@end