1
我正在使用模态视图控制器来在屏幕上显示视图。我有视图设置上的所有内容,并在界面生成器中对齐... 为什么在Interface Builder中运行vs时,我的GUI看起来不同?
但是当我在我的ipad上运行我的应用程序时,事物并未对齐。在第二个屏幕截图中,tableview和dateTimePicker之间存在差距。
在界面生成器我有设定为540x620视图尺寸这是模态的视图的大小。任何想法,当我运行我的应用程序时它看起来不同?
编辑:这就是我目前的观点
// Create the variable that represents the app delegate
KMAppDelegate *delegate = (KMAppDelegate *)[[UIApplication sharedApplication] delegate];
// Create view controller
ModalDetailVC *modalDetailVC = [[ModalDetailVC alloc] initWithNibName:@"ModalDetailVC" bundle:nil];
// Call the pushViewController:animated method from the navigationController variable inside the delegate
[delegate.navigationController pushViewController:modalDetailVC animated:YES];
modalDetailVC.view.superview.frame = CGRectMake(0, 0, 540, 620);
modalDetailVC.view.superview.center = self.view.center;
你是如何呈现其模态?你的观点有哪些自动调整口罩? – 2012-07-30 06:01:39
我编辑了我的帖子以显示我如何呈现视图。 – James 2012-07-30 06:15:11
您不是以模态方式呈现它,而是将其推到导航控制器中。选择器外观的原因可能与缺少自动调整掩码有关 – 2012-07-30 06:19:26