1
当我尝试以模态方式呈现第二个VC时,我收到了此警告。视图控制器演示警告 - 同时呈现两个
Warning: Attempt to present <RCTAddCardViewController: 0x1f5b21e0> on <IRSlidingSplitViewController: 0x1f538140> while a presentation is in progress!
这里是我如何做它:
UIViewController *pvc = [self presentingViewController];
[self dismissViewControllerAnimated:YES completion:^{
RCTAddCardViewController *vc = [[RCTAddCardViewController alloc] initWithNibName:nil bundle:nil];
[pvc presentViewController:vc animated:YES completion:nil];
}];
BC它被提出的第一个VC的解雇完成处理程序中我不应该得到的错误。任何人都知道一种方法让这个消失?
内出于某种原因,当我尝试'在调试PO pvc'我得到一个零 – 2013-04-08 00:42:45
你如果你在'UIViewController * pvc = [self presentingViewController]'后面添加'NSLog(@“%@”,pvc)'', – baris 2013-04-08 00:59:31
那个可以工作。有趣的是'po pvc'也开始不是零。 – 2013-04-08 03:01:09