I've noticed a lot of examples for iPhone apps in the Application Delegate
- (void)applicationDidFinishLaunching:(UIApplication *)application
have
[window addSubview: someController.view];
(1)
as opposed to
self.window.rootViewController = self.someController;
(2)
Is there any practical reason to use one over the other? Is one technically correct? Do controller's have an equivalent command to number (2) like
self.someController.rootController = self.someOtherController; // pseudocode
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…