Fix macish behavoirs

If you have closed the window, the app keeps running, when clicking the
dock icon, the window pops back up.

Update to use @autoreleasepool
missed in last commit somehow, oops!

this should have been part of hte previous commit!