如何在ios中实现标签栏和侧边菜单?

时间:2016-08-11 05:26:25

标签: ios objective-c iphone

对于sidemenu我正在使用SWRevealViewController框架和For tab-bar我正在使用3个Viewcontrollers示例 A B C 。我想在didfinishlaunch中为此目的在初始Viewcontroller中显示标签栏 app delegate中的方法。我已经提到前视图控制器作为标签栏和后视图控制器作为侧面菜单,我也成功地移动到侧面菜单。但是从那个侧面菜单我无法导航视图控制器。请建议我

UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
SideMenuViewController *sidemenuVc = [storyboard instantiateViewControllerWithIdentifier:@"SideMenuViewController"];
HomeViewController *vc = [storyboard instantiateViewControllerWithIdentifier:@"HomeViewController"];
SWRevealViewController *revealController = [[SWRevealViewController alloc] initWithRearViewController:sidemenuVc frontViewController:vc];
//[self .navigationController.pushViewController:vc animcated:YES];
[self.navigationController pushViewController:revealController  animated:YES];

1 个答案:

答案 0 :(得分:0)

你应该像这样创建故事板

Storyboard

或尝试低于Storyboard2