|
From: Leif M. <lei...@ta...> - 2011-05-09 07:22:00
|
Brian, Does your application have a GUI that is being displayed? I just checked and confirmed that console based applications do not cause an icon to be displayed. For Swing applications, you can handle the close even when the user clicks to close the window using the windowClosing method of a WindowListener. But I tried it and the menu bar's Quit choice does not use that. Nor does it appear to be killing it with a TERM signal. Digging around a bit more. I think I found what you want: http://stackoverflow.com/questions/2061194/swing-on-osx-how-to-trap-command-q http://developer.apple.com/library/mac/#samplecode/OSXAdapter/Introduction/Intro.html I have not had a chance to try it out yet, but it looks like this will actually make it possible to cancel the CMD-Q request. We will look into to whether or not it makes sense to add this into the core Wrapper for a future release. Please let me know how this works for you. Cheers, Leif On Thu, May 5, 2011 at 1:36 AM, brian mcgann <br...@gi...> wrote: > I am using wrapper-32-3.5.7.jar and am successfully launching my daemon on > Mac OS X Snow Leopard, however when running, an icon for the daemon appears > on the dock and also appears on the menu bar, complete with a 'Quit' menu > item. How can I avoid this? > > Thanks, > > Brian McGann |