Reputation: 2216
i have a UITabBarController with 5 Items. On one of these ViewController i have a Button, i'm gonna call it "start", so when i press start, i want to have another ViewController Pushed in, but still have the TabBar Visible.
if i use this code
[self presentModalViewController:viewController animated:YES]
the new ViewController hides the TabBar.
Any advices?
Upvotes: 0
Views: 650
Reputation: 406
You can use [self pushViewController:viewController animated:YES]; so tabBar will not hide
Upvotes: 0
Reputation: 17877
What about adding as subview: [self.view addSubview:viewController.view];
. Don't forget to set appropriate frame
for subview.
And don't forget this:
On iPhone and iPod touch devices, the view of modalViewController is always presented full screen. On iPad, the presentation depends on the value in the modalPresentationStyle property.
Upvotes: 2