2009-05-07 141 views

回答

5
//create and start timer 

[NSTimer scheduledTimerWithTimeInterval: 0.05 target: self selector: @selector(timerMethod:) userInfo: nil repeats: YES]; 

// method works 20 times per second 
-(void) timerMethod: (NSTimer*)theTimer { 
NSLog(@"timer is working"); 
} 
相關問題