MoveToNewLocViewContoller *move2NewLocVC = [[MoveToNewLocViewContoller alloc] initWithLocItemArray:moveToNewLocArray andSyLocIDArray:syLocIdArray];
[move2NewLocVC setTitle:cell.textLabel.text];
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:move2NewLocVC];
navController.view.width = PSIsIpad() ? self.view.width : 100;
[navController.navigationBar setTintColor:BLUE];
if (navController) {
[XAppDelegate.menuInterfaceViewController.stackViewController pushViewController:navController fromViewController:nil animated:YES];
[navController release];
//[viewController release];
[moveToNewLocArray release];
[move2NewLocVC release];
}
现在我希望上面的导航控制器在我旋转 ipad 时不会调整大小。我试过 navController.view.autoresizesSubviews = NO;
这可行,但有一个问题,它不允许我的 UITableView(MoveToNewLocViewController) 滚动到底部。避免调整大小的主要目的是避免重绘我巨大的自定义 UITableViewcell 以适应方向。我知道我必须在定向后调整 UiTableview 的大小,但问题是在哪里。我试过
-(void)willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation duration:(NSTimeInterval)duration {}
-(void) didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation {}
它似乎不起作用。这是因为我将它插入到堆叠的容器视图中吗?
任何帮助将不胜感激。