summaryrefslogtreecommitdiffstats
path: root/editor/filesystem_dock.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/filesystem_dock.cpp')
-rw-r--r--editor/filesystem_dock.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/editor/filesystem_dock.cpp b/editor/filesystem_dock.cpp
index b80d3c1869..36f712dde8 100644
--- a/editor/filesystem_dock.cpp
+++ b/editor/filesystem_dock.cpp
@@ -1789,11 +1789,13 @@ void FileSystemDock::_rename_operation_confirm() {
EditorSceneTabs::get_singleton()->set_current_tab(current_tab);
+ if (tree->has_focus()) {
+ current_path = new_path;
+ current_path_line_edit->set_text(current_path);
+ }
+
print_verbose("FileSystem: calling rescan.");
_rescan();
-
- current_path = new_path;
- current_path_line_edit->set_text(current_path);
}
void FileSystemDock::_duplicate_operation_confirm() {