瀏覽代碼

Merge pull request #74626 from KoBeWi/one_line_that_changes_the_fate

Select the newly duplicated file
Yuri Sizov 2 年之前
父節點
當前提交
1182b6eaaa
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      editor/filesystem_dock.cpp

+ 1 - 0
editor/filesystem_dock.cpp

@@ -1286,6 +1286,7 @@ void FileSystemDock::_try_duplicate_item(const FileOrFolder &p_item, const Strin
 		EditorNode::get_singleton()->add_io_error(TTR("Cannot move a folder into itself.") + "\n" + old_path + "\n");
 		return;
 	}
+	const_cast<FileSystemDock *>(this)->path = new_path;
 
 	Ref<DirAccess> da = DirAccess::create(DirAccess::ACCESS_RESOURCES);