I have a tabbed application with each tab having a navigation controller. I use helper code to push a view/controller pair onto the navigation stack yet when I call this same code from two different places I get (suprizingly) different results. In one case the view renders lower than in the other case, seemingly lower by a navigation bar height.
Pushed from one tab (in good position) :
Pushed from another tab (too low):
The XIB:
Here is the push code:
+ (void)navigateToLocation:(Location*)location controller:(UIViewController*)vc withDelegate:(NSObject <LocationEditDelegate> *)delegate {
LocationDetailsViewController *detailsController = [[LocationDetailsViewController alloc] initWithNibName:@"LocationDetailsViewController" bundle:nil];
detailsController.title = [location display];
detailsController.location = location;
detailsController.delegate = delegate;
// Push the detail view controller
[[vc navigationController] pushViewController:detailsController animated:YES];
[detailsController release];
}
Can anybody help me understand what might be going on, and how I get inside this?
I have 2.2.1 installed and build/deploy using 2.2.
Since comments do not appear to show, I am annotating at the bottom. Edit this if I am doing things incorrectly:
- I have added simulated metrics with no change in behavior.