Fix missing dialog on invalid export template file

This fixes the empty dialog box when trying to install invalid export templates files.
This commit is contained in:
Snowdaw 2024-10-08 16:37:08 +02:00 committed by GitHub
parent 842f982397
commit dcaf46c36a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1104,7 +1104,7 @@ ExportTemplateManager::ExportTemplateManager() {
install_file_dialog->set_file_mode(FileDialog::FILE_MODE_OPEN_FILE);
install_file_dialog->set_current_dir(EDITOR_DEF("_export_template_download_directory", ""));
install_file_dialog->add_filter("*.tpz", TTR("Godot Export Templates"));
install_file_dialog->connect("file_selected", callable_mp(this, &ExportTemplateManager::_install_file_selected).bind(false));
install_file_dialog->connect("file_selected", callable_mp(this, &ExportTemplateManager::_install_file_selected).bind(false), CONNECT_DEFERRED);
add_child(install_file_dialog);
hide_dialog_accept = memnew(AcceptDialog);