-
-
Notifications
You must be signed in to change notification settings - Fork 21.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make save confirmation a child of last exclusive window of EditorNode before popup #102070
Make save confirmation a child of last exclusive window of EditorNode before popup #102070
Conversation
That looks super hacky. What if there is another dialog with the same problem? |
The problem lies in these windows being exclusive, so to me it makes sense to reorder the windows/parents depending on the circumstances. Reading out the code into plain English with reference to the documentation. If the editor settings dialog is open, you want the save dialog to always appear on top of it and prevent input to it specifically. Otherwise, it should do the same to the base gui.
Explicitly defining which window is on-top of and blocking which parent seems to me the most straight-forward solution to the problem. I think trying to find ways to do this automatically without the window having direct knowledge of which UI it is trying to block will end up being much hackier looking by comparison.
Probably, but you're going to have to reparent it to something depending on the circumstances anyways, so I think the result will end up looking the same but with more code, and not as clear what the intent is. That isn't to say that unparenting the window when it is invisible isn't beneficial, but it isn't clear to me what that the benefit is (saving resources?) |
ProgressDialog already does this, the currently focused window is not difficult to find. Although manually setting the parent is safer for now I suppose. |
44d10fa
to
f91e1a0
Compare
f91e1a0
to
fe5ec14
Compare
Made some modification based on conversations in Rocket Chat. The solution should be more automatic as mentioned because there already are already multiple scenarios that need to be addressed in the linked PR. This will need reapproval. |
fe5ec14
to
c7fd0bb
Compare
Just updating the name of the commit to match the changes and title. |
Thanks! |
Requires: #102017
This is necessary to prevent multiple exclusive windows on the same parent error.