如何获得这种类型的导航转换?

时间:2018-08-27 06:26:32

标签: objective-c uinavigationcontroller transition

我想要这样的过渡。 Custom Transition

1 个答案:

答案 0 :(得分:0)

您可以使用 CATransition

自定义过渡
CATransition *animation = [CATransition animation];
animation.delegate = self;
animation.duration = 0.25f;
animation.timingFunction = UIViewAnimationCurveEaseInOut;
animation.fillMode = kCAFillModeForwards;
animation.removedOnCompletion = NO;
animation.type = kCATransitionPush;
animation.subtype = kCATransitionFromTop;
[YourView.view.layer addAnimation:animation forKey:@"animation"];
[self.view addSubview:bView];