显然以下内容在 swift 中不再可用:
[self performSelector:@selector(onFlip) withObject:nil afterDelay:0.3];
如果仍然存在以下情况,为什么会出现这种情况:
NSObject.cancelPreviousPerformRequestsWithTarget(self, selector: singleTapSelector, object: nil)
nsobject.cancel 不能与 PerformSelector 一起使用吗?为什么有取消功能但没有执行功能?
Use
NSTimer.scheduledTimerWithTimeInterval(delay, target: self, selector: "onFlip", userInfo: nil, repeats: false)
反而。不知道为什么另一个不可用。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)