最近我在导航堆栈中推送/弹出视图控制器时出现问题,我有一个带有后退按钮的VC,我这样做:
UIButton *backButton = [UIButton buttonWithType:UIButtonTypeCustom];
[backButton setImage:[UIImage imageNamed:@"back-button.png"] forState:UIControlStateNormal];
[backButton addTarget:self action:@selector(popCurrentVC:) forControlEvents:UIControlEventTouchUpInside];
backButton.frame = CGRectMake(0, 0, 67, 31);
UIBarButtonItem *item = [[UIBarButtonItem alloc] initWithCustomView:backButton];
[self.navigationItem setLeftBarButtonItem:item animated:YES];
然后我看到的是按钮在正确的位置淡入,但在某些应用程序中,我确实看到按钮过渡就像,它不仅淡入,而且从RHS移动到LHS,我需要这个效果,我应该在哪里改变,以使按钮渐渐消失和移动?
谢谢!