ios9微信支付报警告: Snapshotting a view that has not been rendered results in an empty snapshot. Ensure yo

来源:互联网 发布:淘宝花呗分期付款 编辑:程序博客网 时间:2024/05/22 06:49

错误代码:Snapshotting a view that has not been rendered results in an empty snapshot. Ensure your view has been rendered at least once before snapshotting or snapshot after screen updates.

解决问题的关键部分来了,IOS8多了一个样式UIModalPresentationOverCurrentContext,IOS8中presentViewController时请将控制器的modalPresentationStyle设置为UIModalPresentationOverCurrentContext,问题解决!!
[Objective-C] 纯文本查看 复制代码
if([[[UIDevice currentDevice] systemVersion] floatValue]>=8.0) {
    self.modalPresentationStyle=UIModalPresentationOverCurrentContext;
}

0 0