Make EditorFileDialog
only created on demand in EditorResourcePicker
#49068
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
My #47260 and #48854 PRs introduced a regression for the Inspector dock. An editor GUI deadlock can be triggered by opening a resource with a lot of sub-resources (such as a
Theme
resource). Apparently, always addingEditorFileDialog
to a control inside of theEditorProperty
makes the dock UI overwhelmed and when done enough times causes it to just hang in a perpetual attempt to re-adjust. In the old version this file dialog was created on demand only, and I can see why now. I've reintroduced this behavior toEditorResourcePicker
.Actually, even
PopupMenu
had a negative effect in the same situation, but it was way smaller. So it's likely all popups for some reason, with the editor file dialog being big enough to become a problem.This also fixes a typo I left in the previous PR 🙃