X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=Classes%2FEnjoyableApplicationDelegate.m;fp=Classes%2FEnjoyableApplicationDelegate.m;h=449f6ef4bab5808164322c42635a91099ea13034;hp=76f99e041bc28eba558258578fa99306783b00f2;hb=b9fcfff94a92aed888c6208ba36059f973d5ca49;hpb=4fea4711168bf73ab807d3b24afd5d5bd8d8978b diff --git a/Classes/EnjoyableApplicationDelegate.m b/Classes/EnjoyableApplicationDelegate.m index 76f99e0..449f6ef 100644 --- a/Classes/EnjoyableApplicationDelegate.m +++ b/Classes/EnjoyableApplicationDelegate.m @@ -112,6 +112,8 @@ - (void)eventSimulationStarted:(NSNotification *)note { self.simulatingEventsButton.state = NSOnState; statusItem.image = [NSImage imageNamed:@"Status Menu Icon"]; + [NSProcessInfo.processInfo + disableAutomaticTermination:@"Event simulation running."]; [NSWorkspace.sharedWorkspace.notificationCenter addObserver:self selector:@selector(didSwitchApplication:) @@ -122,6 +124,8 @@ - (void)eventSimulationStopped:(NSNotification *)note { self.simulatingEventsButton.state = NSOffState; statusItem.image = [NSImage imageNamed:@"Status Menu Icon Disabled"]; + [NSProcessInfo.processInfo + enableAutomaticTermination:@"Event simulation running."]; [NSWorkspace.sharedWorkspace.notificationCenter removeObserver:self name:NSWorkspaceDidActivateApplicationNotification