diff --git a/apple/OSX/platform.h b/apple/OSX/platform.h index 8a0f03f01d..bcee769327 100644 --- a/apple/OSX/platform.h +++ b/apple/OSX/platform.h @@ -43,7 +43,6 @@ NSString* _file; NSString* _core; - bool _isTerminating; bool _loaded; bool _wantReload; } diff --git a/apple/OSX/platform.m b/apple/OSX/platform.m index ec160ac65c..c413ebb901 100644 --- a/apple/OSX/platform.m +++ b/apple/OSX/platform.m @@ -200,7 +200,6 @@ static char** waiting_argv; - (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender { NSApplicationTerminateReply reply = NSTerminateNow; - _isTerminating = true; if (g_extern.main_is_init) reply = NSTerminateCancel; @@ -277,7 +276,7 @@ static char** waiting_argv; [[NSApplication sharedApplication] endSheet:self.coreSelectSheet returnCode:0]; [self.coreSelectSheet orderOut:self]; - if (_isTerminating) + if (g_extern.system.shutdown) return; cb = (NSComboBox*)[[self.coreSelectSheet contentView] viewWithTag:1]; @@ -298,7 +297,7 @@ static char** waiting_argv; - (void)unloadingCore:(const NSString*)core { - if (_isTerminating) + if (g_extern.system.shutdown) [[NSApplication sharedApplication] terminate:nil]; if (_wantReload)