Animation: UIViewAnimationOptions type,
Animation
1. Regular animation attribute settings (multiple options can be selected at the same time) UIViewAnimationOptionLayoutSubviews: ensure that the subview follows the motion during the animation process. ** When an animation is submitted, the Child control is laid out, indicating that the child control will be animated together with the parent control. ** UIViewAnimationOptionAllowUserInteraction: Allows user interaction during the animation process. UIViewAnimationOptionBeginFromCurrentState: all views run from the current state. UIViewAnimationOptionRepeat: re-run the animation. UIViewAnimationOptionAutoreverse: After the animation is run to the end point, it is still returned to the initial point as an animation. ** Execute the animation loop, provided that the animation is set to infinite repetition ** UIViewAnimationOptionOverrideInheritedDuration: Ignore the nested animation time setting. ** Ignore the time variation curve of the nested outer animation ** UIViewAnimationOptionOverrideInheritedCurve: Ignore the nested animation speed setting. ** The animation effect is achieved by changing attributes and re-painting. If the key is not submitted for the animation, the snapshot ** UIViewAnimationOptionAllowAnimatedContent: redraws the view during the animation process (note that it is only applicable to transition animation ). UIViewAnimationOptionShowHideTransitionViews: the old view and new view are directly hidden when the view is switched, instead of removing the old view from the parent view (only applicable to transition animation) ** use an explicit or hidden method to replace the animation effect of removing layers ** UIViewAnimationOptionOverrideInheritedOptions: does not inherit the parent animation setting or animation type. ** Ignore nested inheritance options ** ------------------------------------------------------------------------------------ 2. animation Speed Control (you can select a setting from it) ** UIViewAnimationOptionCurveEaseInOut related to the Time Function Curve: the animation is slow and then gradually accelerates. UIViewAnimationOptionCurveEaseIn: the animation slows down. UIViewAnimationOptionCurveEaseOut: the animation is accelerating. UIViewAnimationOptionCurveLinear: the animation is executed at a constant speed. The default value is. ----------------------------------------------------------------------------- 3. transfer Type (only applicable to transfer animation settings, you can select one of them for setting, basic animation and Key Frame Animation do not need to be set) ** UIViewAnimationOptionTransitionNone related to transfer Animation: no transition animation effect. UIViewAnimationOptionTransitionFlipFromLeft: flipped from the left. UIViewAnimationOptionTransitionFlipFromRight: flipped from the right side. UIViewAnimationOptionTransitionCurlUp: The Animated transition effect for backward paging. UIViewAnimationOptionTransitionCurlDown: transition effect of the animation to the previous page flip. UIViewAnimationOptionTransitionCrossDissolve: the old view disappears and shows the effect of the next new view. UIViewAnimationOptionTransitionFlipFromTop: flipped from the top. UIViewAnimationOptionTransitionFlipFromBottom: The result is flipped from the bottom. Supplement: the last set of transition animation is generally used in this method: [UIView transitionFromView: toView: duration: options: completion: ^ (*** BOOL *** finished) {}]; this method inserts a view and removes one view. Some transition animation effects can be used during this process.
Author: iOS _ ye xiansen
Link: https://www.jianshu.com/p/ec73573e112a
Source: Simplified book
Copyright belongs to the author. For commercial reprint, please contact the author for authorization. For non-commercial reprint, please indicate the source.