In TableView's multi-level tree menu implementation, the reality of multi-level Menu is realized. Many times, in order to make the parent menu more indicative, a downward arrow is added to the Menu, to indicate whether the menu is opened. The following animation effects are usually added. [Cpp] [UIView animateWithDuration: 0.25 animations: ^ (void) {imageView. transform = CGAffineTransformRotate (imageView. transform, 3.1415926);} completion: ^ (BOOL finished) {// set default transform imageView. transform = CGAffineTransformMakeRotation (0); imageView. image = [UIImage imageNamed: @ "new_chevron.png"] ;}]; this imageView is required. transform = CGAffineTransformMakeRotation (0); because the conversion is saved when transform is used for animation, That is, use this imageView to re-open the image next time, and the image will be upside down (because we have rotated it to a π angle (180), so we need to first talk about its rotation back, load the new image. Second, because cell is reused, you cannot use an image to rotate it back and forth to save the rotation effect in imageView (this method is not recommended ). When using the animation effect, we found a very strange phenomenon: when using the system's π # define M_PI 3.14159265358979323846264338327950288/* pi */, it will appear that setting the plural number will not be able to rotate along the needle, it may be that the number of digits is too long, causing overflow. You can define a π with a shorter number of digits, for example, # define ROTATION_M_PI 3.1415926.