`
niCe
  • 浏览: 40345 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论

iPhone中定时器NSTimer使用方法

UP 
阅读更多
- (void) applicationDidFinishLaunching: {

NSTimer *_timer = [[NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(onTimer) userInfo:nil repeats:YES] retain];

}

// call function when time is up (in this exemple :1 second. to change it, change scheduledTimerWithTimeInterval: 1 to value in second)
- (void)onTimer
{
}

 

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics