警告提示:This application is modifying the autolayout engine from a background thread, which can lead to engine corruption and weird crashes. This will cause an exception in a future release.
错误原因:在回调函数中或者后台线程中更新了UI界面,而UI界面必须是在主界面中才能进行修改
解决办法:
dispatch_async(dispatch_get_main_queue(), ^{
<your code>
});
本文讨论了在后台线程中更新UI界面可能导致的应用崩溃问题,并提供了使用dispatch_async和main_queue解决此问题的方法。
2366

被折叠的 条评论
为什么被折叠?



