How to make animation animation UIBarButtonItem?

The iPod app on iPhone has a UIBarButtonItem element in the upper right toolbar that scrolls through songs and track lists for an album. When you select a button, the button itself performs flip animation.

Is there any way to do this with

CGContextRef context = UIGraphicsGetCurrentContext ();
[UIView beginAnimations: nil context: context];

[UIView setAnimationTransition: UIViewAnimationTransitionFlipFromLeft forView: [self superview] cache: YES];

Do I need to create a UIBarButtonItem with initWithCustomView and initWithImage to achieve this?

+5
source share
2 answers

UIBarButtonItem UIView, . (, Apple Maps iPod), , API.

, UIBarButtonItem initWithCustomView, . - .

, ,

+8

- . UIBarButtonItem, , . , UIView, , .

, transitionFromView:toView:options:completion: .

, Apple .

+2

All Articles