The above effects mainly involve point
Nine Gongge layout
Deformation animation
UIView Animation
First, consider the effect of the image, the initial use of the modal controller to achieve, but considering that modal will eventually remove modal his controller's view, so, or use a custom UIView to achieve this feature.
To do this, the first implementation of the button appears in the position, after the implementation of the animation is easy.
Start with nine Gongge layouts, create models to pass in a specified number of buttons, and use a deformation to move all the buttons to invisible coordinates
After clicking the bottom button, set the deformation to the screen area (this is set to cgaffinetransformidentity directly)
Click and Release the Function button to listen (implement touches method can also), the button click on the Function menu button, use the deformation setting button to become larger, release, and then set the deformation becomes larger, and make it transparent to 0
Then click the bottom button to set the deformation to invisible area
After you have identified several function points, the animation effect will say.
Click the bottom button, use UIView elastic animation, each button set a different delay, so that the spring and time interval effect is achieved.
Click on the Function menu, use normal UIView animation when clicked, make the button bigger, loosen, use UIView again, let the button become big and fade away at the same time
After clicking the bottom button again, use the normal UIView animation to hide and zoom out the button in reverse
Article from: TRIPLECC
Project address:Https://github.com/tripleCC/TPCSpringMenu
iOS dev > Learning-Sina Weibo iOS bottom function button simple implementation