Reputation: 2450
I'm in trouble making tab view as I want.
Here's my plan, At the top and bottom, there is each fixed view. so there must be in-between view. At there I want to insert Tab bar and subviewcontrollers.
But by using storyboard and tabbarController, I have to make same fixed views for every sub viewcontroller, isn't it?
How can make it right?
Upvotes: 0
Views: 980
Reputation: 566
You can import view from the tab bar controller to the in-between view in the View controller.
Give a storyboard id to the tab bar controller. Here I am using "Tab".
UIStoryboard* storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
UITabBarController* tab = [storyboard instantiateViewControllerWithIdentifier:@"Tab"];
tab.view.frame = self.inBetweenView.bounds; // replace with your view's name
[self.inBetweenView addSubview:tab.view];
[self addChildViewController:tab];
[tab didMoveToParentViewController:self];
Upvotes: 2