在视图控制器中点击导航栏按钮,实现导航栏按钮和页面的转场动画
//设置点击导航栏按钮事件
- (void)buttonAction:(UIButton *)button {
//取得导航项的父视图
UIView *superView = self.navigationItem.rightBarButtonItem.customView;
UIButton *button1 = (UIButton *)[superView viewWithTag:101];
UIButton *button2 = (UIButton *)[superView viewWithTag:102];
//将按钮的hidden值取反
button1