iOS导航栏、标签栏

View1 *view1 = [[View1 alloc]init];

myNav1 = [[UINavigationController alloc]initWithRootViewController:view1];

view1.title = @”myNav1″;

 

View2 *view2 = [[View2 alloc]init];

myNav2 = [[UINavigationController alloc]initWithRootViewController:view2];

view2.title = @”myNav2″;

 

myTabBar = [[UITabBarController alloc]init];

myTabBar.viewControllers = [NSArray arrayWithObjects:myNav1,myNav2, nil];

myTabBar.view.bounds = CGRectMake(0, 10, 320, 460);

 

[self.view addSubview:myTabBar.view];

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注