#import <Cocoa/Cocoa.h>
@interface AppDelegate : NSObject <NSApplicationDelegate,NSWindowDelegate>
@property (assign) IBOutlet NSWindow *window;
@end
#import "AppDelegate.h"
@implementation AppDelegate
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
{
// Insert code here to initialize your application
self.window.delegate = self;
}
-(BOOL)windowShouldClose:(id)sender
{
[[NSApplication sharedApplication] hide:self];
return NO;
}
@end