The networking code goes off and does it's own thing during the setup. That takes time. Exiting before that finished cause my app to crash as you described. Perhaps there is a better way, but I didn't find it. I doubt ARC will help here.
jnoxx's suggestion is the likely solution, but...
You can connect the back button to a local method, do the things you need done there, and then send the view controller the exit message. I think the final line in that method would be this;Code:[self.navigationController popViewControllerAnimated: YES];
Here is what I did to stop the activity indicator:
Code:
-(void)viewWillDisappear:(BOOL)animated { [UIApplication sharedApplication].networkActivityIndicatorVisible = NO;
[webView stopLoading];
}
That also takes care of stopping the webView too.
Edit: I solved the crashing just now, here's what I had to do:
I moved
Code:
[toolbarStop release];
[toolbarRefresh release];
Last edited: