applicationShouldTerminateAfterLastWindowClosed: does not seem to work when the red x is used to clo

Posted by Michael Minerva on Stack Overflow See other posts from Stack Overflow or by Michael Minerva
Published on 2009-11-12T01:46:27Z Indexed on 2010/05/20 19:00 UTC
Read the original article Hit count: 325

I have a small OSX Cocoa app that just bring up an IKPicutreTaker and saves the picture to a file if one is set. I use applicationShouldTerminateAfterLastWindowClosed: to close the application when the pictureTaker is closed. This all works fine when I either set(this is done when you have picked the picture you want) or when you hit cancel, but when I click on the red arrow in the top left of the windows, the application does not quit when the window is closed this way. Is this intended functionality or am I doing something wrong (not setting some flag?). Also, is there some way to disable this button?

© Stack Overflow or respective owner

Related posts about cocoa

Related posts about osx