ShowFormInDialog() options - disable close box

in the next beta release onHide on a form can return a false to stop the dialog from closing.

This feature is also now available on the main panel (so normal forms) if the onhide of the current showing form returns false then it won't switch to another form.