ios定时器使用的几点优化

1. 将定时器添加到runloop中,通常在viewWillAppear方法中添加 timer = [NSTimer scheduledTimerWithTimeInterval:3.0 target:self selector:@selector(dealTimer) userInfo:nil repeats:YES];app         [[NSRunLoop currentRunLoop
相关文章
相关标签/搜索