启动3S延时执行有一份
[self performSelector:@selector(didRuninCurrModel:) withObject:@(YES) afterDelay:3.0f];
在做取消操作时有两个坑
1,要在主线中执行取消
2,需要注意的是参数的一致性否则取消不掉
[NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(didRuninCurrModel:) object:@(YES)];
Last updated 6 years ago