Why do I have to do this in order to get the sub view of the application window in the right position?
- (void)applicationDidFinishLaunching:(UIApplication *)application {
groupViewController = [[GroupMemberPickerViewController alloc]
initWithNibName:@"GroupMemberPickerViewController"
bundle:[NSBundle mainBundle]];
window.frame = [UIScreen mainScreen].applicationFrame;
[window addSubview: groupViewController.view];
[window makeKeyAndVisible];
}
I mean why do I have to set the window's frame to match the application's frame?. Because if I don't do this the sub view is located 5 px to the top. I just created a new window based project and add the following code. I did not touch any xib file apart from the sub view that I'm setting, but I did not touch nothing related to layout and position.