The Great ScriptCanvas Purge, Part V
Signed-off-by: chcurran <82187351+carlitosan@users.noreply.github.com>
This commit is contained in:
@@ -148,37 +148,13 @@ namespace ScriptCanvasEditor
|
||||
|
||||
}
|
||||
|
||||
bool IsValidSourceFile(const AZStd::string& filePath, ScriptCanvas::ScriptCanvasId scriptCanvasId)
|
||||
bool IsValidSourceFile(const AZStd::string& filePath, [[maybe_unused]] ScriptCanvas::ScriptCanvasId scriptCanvasId)
|
||||
{
|
||||
bool isValidSourceFile = true;
|
||||
|
||||
if (scriptCanvasId.IsValid())
|
||||
ScriptCanvasAssetDescription assetDescription;
|
||||
return AZ::StringFunc::EndsWith(filePath, assetDescription.GetExtensionImpl(), false);
|
||||
{
|
||||
bool isRuntimeGraph = false;
|
||||
EditorGraphRequestBus::EventResult(isRuntimeGraph, scriptCanvasId, &EditorGraphRequests::IsRuntimeGraph);
|
||||
|
||||
if (isRuntimeGraph)
|
||||
{
|
||||
ScriptCanvasAssetDescription assetDescription;
|
||||
|
||||
if (!AZ::StringFunc::EndsWith(filePath, assetDescription.GetExtensionImpl(), false))
|
||||
{
|
||||
isValidSourceFile = false;
|
||||
}
|
||||
}
|
||||
// Assume it's a function for now
|
||||
else
|
||||
{
|
||||
ScriptCanvasEditor::ScriptCanvasFunctionDescription assetDescription;
|
||||
|
||||
if (!AZ::StringFunc::EndsWith(filePath, assetDescription.GetExtensionImpl(), false))
|
||||
{
|
||||
isValidSourceFile = false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
return isValidSourceFile;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user