控制臺(tái)報(bào)錯(cuò):
This application is modifying the autolayout engine from a background thread after the engine was accessed from the main thread. This can lead to engine corruption and weird crashes.
dispatch_async(dispatch_get_main_queue(), ^{
//將調(diào)用方法添加到主線程
});