Yeah, this is a bit of a tricky one, because when you’re running a modal box, you’re already running an inner loop inside code belonging to the thing that you need to delete, so it’s quite hairy. Ideally, it just shouldn’t be able to close the window while there’s a dialog box open, but that requires OS-level changes. I’ve been thinking about this lately so might add something soon.
But the safest thing is just to avoid any modal loops - just open your dialog boxes as normal windows and delete them when the editor window is closed.
Nobody else has troubles with that? avoid using modal loops is a solution but it’s not perfect as you cannot really have an a component that blocks the focus on itself. no popup menu…
or is it possible?
Jules, any directions where I could look to change that?