I'm trying to disable input to a window after a button is clicked, while the operation is in progress. If I open a new full screen window and put that over the current window, the user is not able to (accidentally) click the button again until the operation has completed - since this can cause a crash if two alert dialogs pop up at once, for example. But switching to a different window is distracting - I'd much prefer a small loading indicator in the middle of the screen.
If I simply make the window smaller, the parts the window doesn't reach are still clickable. So I thought of making a full screen window and making it completely transparent, but when the opacity is set to 0 it's treated as hidden, and events go to the underlying window instead. So I've ended up having to set an opacity of 0.05 and you can see the full window dim a little when an action is initiated. Is there a better way to do this? Something like window.enabled = false would be great.