UIViewController *topRootViewController = [[UIApplication sharedApplication] keyWindow].rootViewController;
// 在这里加一个这个样式的循环
while(topRootViewController.presentedViewController)
{
// 这里固定写法
topRootViewController = topRootViewController.presentedViewController;
}
// 然后再进行present操作
[topRootViewController presentViewController:picker animated:YEScompletion:nil];
网友评论