Reputation:
if you make an app that has a main menu does every one of those menu items normally take you to a new xib file? Or can you set everything up in one xib and set .hide to true or something like that so that only some items show?
Just wondering, i'm just getting started with iOS.
Upvotes: 1
Views: 264
Reputation: 16714
Usually separate views are held in different xib files and controlled by separate UIViewControllers.
Upvotes: 3
Reputation: 13386
It depends. If the "second page" (the one you're taken to when you tap menu item) contains some generic layout like some text area and image and some label etc… then it's a good idea, to have only one xib and just fill it with different data.
But when you have different layouts I'd recommend you to use different xibs as it's unnatural (and can be hard to maintain later on) to hide some stuff and make a voodoo dance just to have all your layouts in one xib.
P.S. One more off topic advice. Check out the storyboards introduced in SDK5. They are very easy to use while building your app in interface builder
Upvotes: 0