| |||
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
How do I add in some "cleanup" code so that everything exits as it
should?
- (void)applicationWillTerminate:(NSNotification *)aNotification-jcr
Sent by the default notification center immediately before the application terminates. aNotification is always an NSApplicationWillTerminateNotification. You can retrieve the NSApplication object in question by sending object to aNotification. Put any necessary cleanup code in this method.
applicationWillTerminate: does not get called for logout for power-off. See NSWorkspaceWillPowerOffNotification, which is sent for these events.
See Also: - applicationShouldTerminate:, - terminate:
| References: | |
| >The Quit menu item (From: email@hidden (Ben Mackin)) |
| Home | Archives | FAQ | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.