下面是流量,我想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 –