美文网首页我爱编程IOS
whose view is not in the window

whose view is not in the window

作者: 开心就好2008 | 来源:发表于2018-02-22 16:10 被阅读0次

 UIViewController *topRootViewController = [[UIApplication  sharedApplication] keyWindow].rootViewController;

            // 在这里加一个这个样式的循环

            while(topRootViewController.presentedViewController)

            {

                // 这里固定写法

                topRootViewController = topRootViewController.presentedViewController;

            }

            // 然后再进行present操作

            [topRootViewController presentViewController:picker animated:YEScompletion:nil];

相关文章

网友评论

    本文标题:whose view is not in the window

    本文链接:https://www.haomeiwen.com/subject/gpgynxtx.html