You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-17 14:11:06 +00:00
Fix Project Manager hard crashes due to invalid access to Editor Nodes
This commit is contained in:
@@ -1099,16 +1099,18 @@ EditorFileDialog::Access EditorFileDialog::get_access() const {
|
||||
}
|
||||
|
||||
void EditorFileDialog::_make_dir_confirm() {
|
||||
if (EditorFileSystem::get_singleton()->get_filesystem_path(makedirname->get_text().strip_edges())) {
|
||||
const String stripped_dirname = makedirname->get_text().strip_edges();
|
||||
|
||||
if (dir_access->dir_exists(stripped_dirname)) {
|
||||
error_dialog->set_text(TTR("Could not create folder. File with that name already exists."));
|
||||
error_dialog->popup_centered(Size2(250, 50) * EDSCALE);
|
||||
makedirname->set_text(""); // Reset label.
|
||||
return;
|
||||
}
|
||||
|
||||
Error err = dir_access->make_dir(makedirname->get_text().strip_edges());
|
||||
Error err = dir_access->make_dir(stripped_dirname);
|
||||
if (err == OK) {
|
||||
dir_access->change_dir(makedirname->get_text().strip_edges());
|
||||
dir_access->change_dir(stripped_dirname);
|
||||
invalidate();
|
||||
update_filters();
|
||||
update_dir();
|
||||
|
||||
Reference in New Issue
Block a user