From 672ca71e4b3d3ceea7b59dc2a81a310e70f4be5c Mon Sep 17 00:00:00 2001 From: Ganesh Srinivasson Date: Mon, 20 Apr 2026 17:04:11 +0200 Subject: [PATCH] Fix app quitting when opening the first document from the Open dialog --- src/main.m | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/main.m b/src/main.m index 916d893..cfe735e 100644 --- a/src/main.m +++ b/src/main.m @@ -694,7 +694,7 @@ - (NSMenuItem *)standardMenuItemWithTitle:(NSString *)title } - (BOOL)applicationShouldTerminateAfterLastWindowClosed:(NSApplication *)sender { - return YES; + return NO; } - (void)applicationDidFinishLaunching:(NSNotification *)notification { @@ -830,9 +830,6 @@ - (void)openDocument:(id)sender { [NSApp activateIgnoringOtherApps:YES]; if ([panel runModal] != NSModalResponseOK) { - if (self.windowControllers.count == 0) { - [NSApp terminate:nil]; - } return; }