moreThanOneInstanceAllowed() / anotherInstanceStarted()

Cool little mechanism…

I want to only allow one instance. I’m returning FALSE for moreThanOneInstanceAllowed()

I’m getting notified in anotherInstanceStarted() when i try to start the second app. Upon doing so i just setVisible(true) on my main window…

everything looks good (original instance is visible, new instance isn’t)… except the second instance still shows up in the process manager. ie., it never got killed.

is this something i’m expected to handle?



I do the same thing, but I’ve never had that problem. Don’t suppose you could post your juceapp class code?

Take a look at the code for it in JUCEApplication::enterMainApplicationLoop - you could try stepping through it in the debugger.

It should always exit immediately because it’ll never enter the event loop, but let me know if you find a problem with it.