Using ViewControllers
My iPhone App is a child's game and I have about 20 different views that I want to randomly switch between. Now I have watched Nick Myers'
iPhone Tutorial - Multiple XIB files on Vimeo (iPhone Tutorial - Multiple XIB files on Vimeo), however, he is only switching between two views & nibs and does not release the first viewController. I have tried to set-up my app in this manner and get it to switch fine enough, but I must be doing something wrong still, because it isn't releasing the view controllers.
Could someone please explain why I need to have ViewControllers & Views for each XIB instead of just putting all the code in the ViewControllers and forgetting the views altogether? I have the code for switching the views in the AppDelegate file, is this a good way?
In my game, when each view shows up it asks you to touch a certain item on the screen.
HOW IS THE BEST WAY TO SET THINGS UP HERE?
iPhone Tutorial - Multiple XIB files on Vimeo (iPhone Tutorial - Multiple XIB files on Vimeo), however, he is only switching between two views & nibs and does not release the first viewController. I have tried to set-up my app in this manner and get it to switch fine enough, but I must be doing something wrong still, because it isn't releasing the view controllers.
Could someone please explain why I need to have ViewControllers & Views for each XIB instead of just putting all the code in the ViewControllers and forgetting the views altogether? I have the code for switching the views in the AppDelegate file, is this a good way?
In my game, when each view shows up it asks you to touch a certain item on the screen.
HOW IS THE BEST WAY TO SET THINGS UP HERE?
JermGuy Wrote:Could someone please explain why I need to have ViewControllers & Views for each XIB instead of just putting all the code in the ViewControllers and forgetting the views altogether? I have the code for switching the views in the AppDelegate file, is this a good way?
You don't. It's just convenient if you want to design your views in Interface Builder. If you eliminate xibs, your view controllers can become views.

