我一次将UIViewController推到导航控制器中,另一次通过插入导航控制器的根视图来呈现它。
第一种情况:作为导航控制器的第二张幻灯片
[self.navigationController pushViewController:riassunto animated:YES];第二种情况:作为模态视图的根
UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:riassunto];
navigationController.navigationBarHidden = NO;
[[navigationController navigationBar] setBarStyle:UIBarStyleBlack];
[self presentViewController:navigationController animated:NO completion:nil];但这种观点的立场是不同的:
第一例

第二例

似乎在第二种情况下,模态视图,视图不会向下移动,以腾出空间到顶部栏。为什么?
发布于 2013-10-25 08:05:44
在第二个视图控制器中尝试使用此方法:
riassunto.edgesForExtendedLayout = UIRectEdgeNone;要了解更多信息,我将扩展这个答案:
https://stackoverflow.com/questions/19584248
复制相似问题