Merge pull request #45233 from YeldhamDev/filedock_path_fix

Update path in the FileSystem dock after doing file operations
This commit is contained in:
Rémi Verschelde 2021-01-26 15:24:35 +01:00 committed by GitHub
commit f6af5b6eac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 12 additions and 0 deletions

View File

@ -1407,10 +1407,16 @@ void FileSystemDock::_make_scene_confirm() {
void FileSystemDock::_file_removed(String p_file) {
emit_signal("file_removed", p_file);
path = "res://";
current_path->set_text(path);
}
void FileSystemDock::_folder_removed(String p_folder) {
emit_signal("folder_removed", p_folder);
path = "res://";
current_path->set_text(path);
}
void FileSystemDock::_rename_operation_confirm() {
@ -1465,6 +1471,9 @@ void FileSystemDock::_rename_operation_confirm() {
print_verbose("FileSystem: saving moved scenes.");
_save_scenes_after_move(file_renames);
path = new_path;
current_path->set_text(path);
}
void FileSystemDock::_duplicate_operation_confirm() {
@ -1573,6 +1582,9 @@ void FileSystemDock::_move_operation_confirm(const String &p_to_path, bool p_ove
print_verbose("FileSystem: saving moved scenes.");
_save_scenes_after_move(file_renames);
path = "res://";
current_path->set_text(path);
}
}