下面是流量,我想Loginvc-> tabbarvcontroller(4tab)(也与左右侧栏)左右侧栏+ tabbarController(IOS的ObjectiveC)
我的问题是
我想做 1)后登录隐藏后杠按钮+添加左侧右侧边栏+ tabbarcontroller
但是,当我实现backbarbutton不隐藏,它加载tabbarcontroller页面而不是tab1。
感谢inadvance
下面是流量,我想Loginvc-> tabbarvcontroller(4tab)(也与左右侧栏)左右侧栏+ tabbarController(IOS的ObjectiveC)
我的问题是
我想做 1)后登录隐藏后杠按钮+添加左侧右侧边栏+ tabbarcontroller
但是,当我实现backbarbutton不隐藏,它加载tabbarcontroller页面而不是tab1。
感谢inadvance
试试这个步骤:
1. set TabViewControllerID in storyboard . and then set tabbarView controller as rootviewcontroller of app delegate using app delegate object after successful login.
UITabBarController * tabBarController = [storyboard instantiateViewControllerWithIdentifier:@"TabbarControllerID"];
AppDelegate *appDelegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
appDelegate.window.rootViewController = tabBarController;
2 . Add left bar button in your tabViewController’s Viewcontroller .
3. and use MFSideMenu third party library for left and right menu.
你好,谢谢你的回答,但我试过你的解决方案,但没有发现运气问题1)如何为tabbarcontroller和另一个侧栏分配两个rootviewcontroller 2)如果我删除侧边栏和单独的tabbar窗口也创建问题时,导致出界问题。谢谢 –
UIStoryboard*Storyboard=[AppDelegate storyBoardType];
tbTBC *tabvc=(tbTBC*)[Storyboard instantiateViewControllerWithIdentifier:@"tbTBCId"];
NSLog(@"tabvc controller ===>%@",tabvc.viewControllers);
tabvc.selectedIndex=3;//set tabbar index number to push on that particular tab bar
[self.revealViewController setFrontViewController:tabvc];
[self.revealViewController setFrontViewPosition: FrontViewPositionLeft animated: YES];
你推登录后tabvieecontroller? – KKRocks
登录后,tabbarcontroller应该是您的根视图。 –
@KKRocks 1)是登录后推送tabviewcontroller –