iOS 怎麼設置 UITabBarController 的第n個item為第一響應者? UITabBarController 裡面有個屬性:selectedIndex @property(nonatomic) NSUInteger selectedIndex; UITabBarController ...
iOS 怎麼設置 UITabBarController 的第n個item為第一響應者?
UITabBarController 裡面有個屬性:selectedIndex
@property(nonatomic) NSUInteger selectedIndex;
UITabBarController *VC = [[UITabBarController alloc]init];
VC.selectedIndex = n-1;
[self.navigationController pushViewController:VC animated:YES];