Ana*_*d Y 5 unrecognized-selector ecslidingviewcontroller
我最近将 Xcode 更新到版本 11.3.1,之后我无法运行我的应用程序。我遇到了以下异常:
2020-02-11 16:13:04.767795-0600 UVM[5204:80616] -[ECSlidingViewController notifyWhenInteractionChangesUsingBlock:]:无法识别的选择器发送到实例 0x7f8258016c00
2020-02-11 16:13:04.785346-0600 UVM[5204:80616] *** 由于未捕获的异常“NSInvalidArgumentException”而终止应用程序,原因:“-[ECSlidingViewController notificationWhenInteractionChangesUsingBlock:]:无法识别的选择器发送到实例 0x7f8258016c00”
在我更新 Xcode 之前它工作得很好。谁能帮我解决这个问题?
看起来以下方法已被弃用,并且它是在启动期间引发异常的方法。
- (void)notifyWhenInteractionEndsUsingBlock:(void(^)(id<UIViewControllerTransitionCoordinatorContext>context))handler {
self.coordinatorInteractionEnded = handler;
}
Run Code Online (Sandbox Code Playgroud)
它在 ECSlidingViewController.m 中
如果我们注释掉该方法并添加以下方法,应用程序将再次正常工作:
- (void)notifyWhenInteractionChangesUsingBlock:(nonnull void (^)(id<UIViewControllerTransitionCoordinatorContext> _Nonnull))handler {
self.coordinatorInteractionEnded = handler;
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
351 次 |
| 最近记录: |