On Sun, Mar 23, 2008 at 9:55 PM, Samvel <[EMAIL PROTECTED]> wrote: > Hi, > > I have defined class (say, Download) that uses NSURLConnection to > download something from internet. My application is Cocoa with UI. I > want to call: > > [Download cancel] > > and wait for notification from this class once user quits application.
In your app delegate, implement -applicationShouldTerminate: to call the above cancel method and return NSTerminateLater. Then, when the cancellation is done, call [NSApp replyToApplicationTerminate:YES]. Or NO, to cancel the termination request. sherm-- _______________________________________________ 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 [EMAIL PROTECTED]