2011年4月8日 星期五

UIKit and thread

when dealing with UIKit class, we must be in the main thread
If we are not in the main thread,
and we want to modify label's text,
we must do following
->

[textLabel performSelectorOnMainThread:@selector(setText:)  
      withObject:@"hello" waitUntilDone:YES];

沒有留言:

張貼留言