On Sep 8, 2009, at 1:43 PM, Colin Deasy wrote:
Spot on, thanks man. Fixed it using: [[NSRunLoop currentRunLoop] runUntilDate:[NSDate distantFuture]]; while ([self isDownloading] );
This will work, but you won't be able to know if your NSInvocationQueue wants to cancel. If that's important, then this would be better:
while ([self isDownloading] && ![self isCancelled]) {[[NSRunLook currentRunLoop] runUntilDate:[NSDate dateWithTimeIntervalSinceNow:0.001]];
}This assumes that your object inherits from NSOperation. You might also want to cancel the NSURLConnection if the operation gets cancelled.
-- Dave Carrigan d...@rudedog.org Seattle, WA, USA
PGP.sig
Description: This is a digitally signed message part
_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com