Check for existing asset meta in browser file before sendin asset id

This commit is contained in:
Xiao Qi 2023-02-22 16:49:21 +08:00
parent 5623115e29
commit 8e9854a130
2 changed files with 5 additions and 1 deletions

View File

@ -441,6 +441,10 @@ namespace SHADE
if (genMeta) if (genMeta)
{ {
GenerateNewMeta(newPath); GenerateNewMeta(newPath);
}
else
{
//send event here
} }
} }

View File

@ -233,7 +233,7 @@ namespace SHADE
{ {
if(ImGui::Selectable("Compile")) if(ImGui::Selectable("Compile"))
{ {
SHAssetManager::CompileAsset(file.path, !file.compiled, file.assetMeta->id); SHAssetManager::CompileAsset(file.path, !file.compiled, file.assetMeta ? file.assetMeta->id : 0);
QueueRefresh(); QueueRefresh();
} }
ImGui::EndPopup(); ImGui::EndPopup();