Gui*_*ume 23
UITabBar继承自UIView,因此您可以像使用标准UIView一样隐藏它并为其设置动画.
- (void) hideTheTabBarWithAnimation:(BOOL) withAnimation {
if (NO == withAnimation) {
[theTabBar setHidden:YES];
} else {
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDelegate:nil];
[UIView setAnimationDuration:0.75];
[theTabBar setAlpha:0.0];
[UIView commitAnimations];
}
}
Run Code Online (Sandbox Code Playgroud)
Pra*_*tel 23
您应该使用此代码:
self.tabBarController.tabBar.hidden=YES;
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
23462 次 |
| 最近记录: |