Add support for editing path to the asset within AssetRefEditor

This commit is contained in:
Wojtek Figat
2023-01-15 23:05:58 +01:00
parent 07e653468f
commit eff24ed836
8 changed files with 312 additions and 112 deletions

View File

@@ -1024,10 +1024,9 @@ namespace FlaxEditor.Utilities
/// <returns>The processed name path.</returns>
public static string GetAssetNamePath(string path)
{
if (path.StartsWith(Globals.ProjectFolder))
{
path = path.Substring(Globals.ProjectFolder.Length + 1);
}
var projectFolder = Globals.ProjectFolder;
if (path.StartsWith(projectFolder))
path = path.Substring(projectFolder.Length + 1);
return StringUtils.GetPathWithoutExtension(path);
}