我试图运行一个方法,当我的应用程序启动时涉及到呈现模态视图。模态视图出现,因为我可以看到它覆盖状态栏,但它永远不会超出现有视图的前端。在应用程序上显示模态视图启动叶子隐藏在另一个视图后
我在viewDidAppear:(BOOL)动画方法中试过这个,但这对问题没有任何影响。
如果我在应用程序加载时通过点击按钮调用方法并显示模式视图,它应该会显示在顶部。
我是否错过了某些东西,或者有没有办法强制模态视图出现在前面?
的代码我使用目前的看法是这样的
- (void)viewDidAppear:(BOOL)animated {
ModalView *modalView = [[ModalView alloc] initWithNibName:@"ModalView" bundle:nil];
modalView.modalPresentationStyle = UIModalPresentationFullScreen;
[self presentModalViewController:modalView animated:YES];
[modalView release];
}
然而,这是所谓的zbar和一个SDK调用所以我也发出了疑问给他们,如果什么奇怪找出正在进行,以防万一它不是我正在做的事情。
两天前我有同样的问题。你可以显示你的代码吗?你需要过渡来展示你的观点吗? – 2011-04-30 13:06:08
我的视图代码非常多。 - (void)viewDidAppear:(BOOL)animated {modalView * modalView = [[ModalView alloc] initWithNibName:@“ModalView”bundle:nil]; modalView.modalPresentationStyle = UIModalPresentationFullScreen; [self presentModalViewController:modalView animated:YES]; [modalView发布]; } – 2011-04-30 22:13:58