I've been wrestling with this for a while. I need to show additional information about the current view (which is a detail view itself).
Here's some images to show what I mean (it's not my app, but will similar design).
The first view is top level navigation view. When the user drills down, they eventually end up with the second view (detail view). On the tab bar there're additional info about the detail (Benelli gun).
The problem is that I do not know a clean way to implement another tabbar controller/tabbar inside the original top level tabbar. Pushing a tabbarcontroller inside tabbar controller is messy and I haven't been able to get it to work cleanly.
So while a second "detail tabbar" would be nice, I'm exploring othe开发者_高级运维r ways.
I tried putting in a custom table with detail views but it doesn't look natural under the description (stats).
Looking for design suggestions, thanks.
I would use a segmented controller to display your options for the detail view. You can put it at the bottom of your view in place of the UITabBar if you use the hidesBottomBarWhenPushed property of the detail view controller to hide the tab bar.
Why not just replace the buttons programmatically when you go to a proper section?
You can completely manipulate the tab bar buttons at run time can't you? That's probably what they do.
This could just be a custom UIView at the bottom of the detail view, right? The custom view has a custom background, and 4 button, No? Pretty good idea if you ask me.
Implement this as follows,
1) Create two diff tabBarControllers(each with 4 UIViewControllers).
2) When you want to change the tabBarController change the viewController.
(Note: don't use [self presentModalViewController:vc animated:NO]
because here self
won't point to the tabBarControllers instance, so use the tabBarControllers instance)
精彩评论