Fix regression from 21e2c830e5 when reimport Animation

#3937
This commit is contained in:
Wojtek Figat
2026-03-25 18:44:56 +01:00
parent 56b208ad85
commit 3f2e6d82c9
2 changed files with 13 additions and 0 deletions

View File

@@ -431,6 +431,9 @@ namespace FlaxEditor.Windows.Assets
_isWaitingForTimelineLoad = true;
base.OnItemReimported(item);
// Drop virtual asset state and get a new one from the reimported file
LoadFromOriginal();
}
/// <inheritdoc />

View File

@@ -527,6 +527,16 @@ namespace FlaxEditor.Windows.Assets
return false;
}
/// <summary>
/// Loads the asset from the original location to reflect the state (eg. after original asset reimport).
/// </summary>
protected virtual void LoadFromOriginal()
{
_asset = LoadAsset();
OnAssetLoaded();
ClearEditedFlag();
}
/// <inheritdoc />
protected override T LoadAsset()
{