Hi there 
In my application, I have a class. It's just a class that does some other stuff, but along with that other stuff, I need it to respond as the application delegate to the applicationWillTerminate or applicationShouldTerminate methods. Unfortunately, even after having set the application delegate via. code and Interface Builder, neither one of those methods work.
I'm setting the application delegate in the awakeFromNib method of this class like this:
And I'm using the methods like this:
Also, that method was placed in the header file. I don't know if that matters or not.
Any help would be appreciated! Thanks.
In my application, I have a class. It's just a class that does some other stuff, but along with that other stuff, I need it to respond as the application delegate to the applicationWillTerminate or applicationShouldTerminate methods. Unfortunately, even after having set the application delegate via. code and Interface Builder, neither one of those methods work.
I'm setting the application delegate in the awakeFromNib method of this class like this:
Code:
[[NSApplication sharedApplication] setDelegate:self];
And I'm using the methods like this:
Code:
- (void)applicationShouldTerminate:(NSNotification *)aNotification {
NSLog(@"It'd be great if this actually ran...");
}
Also, that method was placed in the header file. I don't know if that matters or not.
Any help would be appreciated! Thanks.