2011-07-21 14 views

答えて

2
- (void)viewDidLoad 
{ 
    [self performSelectorInBackground:@selector(startFatching) withObject:nil]; 
     [super viewDidLoad]; 
} 
- (void) startFatching 
{ 
    [self performSelectorOnMainThread:@selector(startIndicator) withObject:nil waitUntilDone:NO]; 

    NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; 

     // your code 

     [self performSelectorOnMainThread:@selector(stopIndicator) withObject:nil waitUntilDone:NO]; 
[pool release]; 
} 

- (void) startIndicator 
{ 
    av.hidesWhenStopped = YES; 
    [av startAnimating]; 
} 

- (void) stoprIndicator 
{ 
    [av stopAnimating]; 
} 

希望これはあなたの

+0

はい..おかげで、いくつかのアイデアを与えるだろう... –

関連する問題