A UITabBarController
and UINavigationController
are based on fundamentally different paradigms.
The UITabBarController
is intended for the UIViewController
on each tab to exist independently of each other and for the user to choose which they want to view. viewDidLoad
only gets called once for each UIViewController
because it is intended that each tab still exists in memory even as the user switches to a different tab.
The UINavigationController
is a stack of UIViewControllers
where each is related to the one above and beneath itself. The top UIViewController
in the stack is always the one that is visible to the user. When a UIViewController
is pushed to the stack, its viewDidLoad
gets called because it is being loaded into memory. When the top UIViewController
gets poped off the stack, it is unloaded from memory, and viewDidUnload
gets called on the way out (viewDidUnload
is deprecated in iOS6 and won't get called, but the controller will still get dumped from memory). This is why viewDidLoad
gets called every time that the user pushes a particular UIViewController
onto the UINavigationController
stack.