Add file open / save prompts in scripting API by dogboydog · Pull Request #3782 · mapeditor/tiled (original) (raw)
added 3 commits
dogboydog marked this pull request as ready for review
Added ResetBlocker instances to avoid script reload while a file dialog is open.
A ResetBlocker instance was also needed in ScriptDialog::exec, to avoid scripts reloading while a dialog is open in modal mode.
- promptForDirectory -> promptDirectory (seems more consistent)
- promptOpenMultipleFiles -> promptOpenFiles (seems less redundant)
I'm a little undecided about dropping the "Names" postfix that is used by the Qt API. I think it might help to keep it to make it clear that file names are returned, as opposed to some kind of file objects, but it does also feel a little verbose.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})