From ab43ce8f30cd6b286e002ee734344e50ba816c18 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Sat, 19 Nov 2016 09:24:21 -0500 Subject: Low Battery Yup: Close the application when window is closed This app has only one window and one function. Since it's so simple, it only needs to be open for a short time. It should close when its window is closed. --- Low Battery Yup/AppDelegate.m | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Low Battery Yup/AppDelegate.m b/Low Battery Yup/AppDelegate.m index 0c9bbdc..e5b9d90 100644 --- a/Low Battery Yup/AppDelegate.m +++ b/Low Battery Yup/AppDelegate.m @@ -20,4 +20,9 @@ // Insert code here to initialize your application } +- (BOOL)applicationShouldTerminateAfterLastWindowClosed:(NSApplication *)theApplication +{ + return YES; +} + @end -- cgit v1.2.3