BUG: Self can lose track when MessageDialog.ShowModalWithin is used

I have multiple instances of a window that, upon a Timer action after opening, show a dialog using MessageDialog.ShowModalWithin(self). One of the options in the dialog is to close the window.

If two such windows are open, showing that dialog, and the user clicks on a different window to press the “Close” button, the first window closes. It seems like Self is losing track somewhere within ShowModalWithin.

See <https://xojo.com/issue/55280>.