Modal dialog box in a NPAPI plugin

I have a NPAPI plugin (not built using JUCE framework) … which creates a JUCE dialog box. I want this dialog box to be modal …
I am able to get the dialog box to show up … but its not coming up as a modal dialog box.

How do I get this working inside a plugin ?


I really don’t recommend doing anything modally in a plugin. If the host decides to get rid of your plugin while it’s running a modal loop, the stack can’t be unwound and it’ll cause a very nasty crash.