Switch the animation effect on the Xcode interface and xcode switch the animation
CATransition * animation = [CATransitionanimation];
[AnimationsetDuration: 0.2f];
[Animation setTimingFunction: [CAMediaTimingFunction
FunctionWithName: kCAMediaTimingFunctionEaseIn];
[Animation setType: kCATransitionPush];
If (isLeft ){
[Animation setSubtype: kCATransitionFromLeft];
} Else {
[Animation setSubtype: kCATransitionFromRight];
}
[BottomView. layeraddAnimation: animation forKey: @ "Reveal"];
Copy the Code directly to the location where you need to switch the interface. BottomView is the interface for switching the interface.
For details about the parameters, refer to the settings for switching animation effects.
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.