Ive discovered the setModalState function, and I think that this could be quite useful if it is what I think it is. But what exactly is it?

The comments say that if I pass true in as an argument when calling this function on a window then "this Window will be activated and set as the modal target."
Ive done just this as a quick test, but it doesnt seem to do anything. I think my understanding of a modal window in this context is not quite right: if a window is modal, then only this window will be active i.e. continue to receive events, and all other windows in the system will be inactive. Am I on the wrong track here?