From 8bd04594dd8d9288e08da5c153907f5dfe210fcc Mon Sep 17 00:00:00 2001 From: o1 Date: Thu, 15 Jan 2015 16:57:22 +0300 Subject: [PATCH] Cog will now re-maximize window(s) when dock icon clicked after minimization. --- Application/AppController.m | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Application/AppController.m b/Application/AppController.m index 540e6f928..c735c8943 100644 --- a/Application/AppController.m +++ b/Application/AppController.m @@ -401,7 +401,11 @@ increase/decrease as long as the user holds the left/right, plus/minus button */ - (BOOL)applicationShouldHandleReopen:(NSApplication *)theApplication hasVisibleWindows:(BOOL)flag { if (flag == NO) - [mainWindow makeKeyAndOrderFront:self]; + [mainWindow makeKeyAndOrderFront:self]; // TODO: do we really need this? We never close the main window. + + for(NSWindow* win in [NSApp windows]) // Maximizing all windows + if([win isMiniaturized]) + [win deminiaturize:self]; return NO; }