Files
UnrealEngineUWP/Engine/Plugins/Runtime/ModelViewViewModel/Source/ModelViewViewModelBlueprint/Private/MVVMConversionFunctionGraphSchema.h
patrick boutot 146c084883 MVVM: Enable K2Node as conversion functions.
#jira UE-190393
#rb editor-ui-systems

[CL 30592808 by patrick boutot in ue5-main branch]
2024-01-12 10:07:58 -05:00

28 lines
727 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "EdGraphSchema_K2.h"
#include "MVVMConversionFunctionGraphSchema.generated.h"
/**
*
*/
UCLASS()
class UMVVMConversionFunctionGraphSchema : public UEdGraphSchema_K2
{
GENERATED_BODY()
public:
virtual const FPinConnectionResponse CanCreateConnection(const UEdGraphPin* A, const UEdGraphPin* B) const override
{
FPinConnectionResponse ConnectionResponse = Super::CanCreateConnection(A, B);
if (ConnectionResponse.Response == CONNECT_RESPONSE_MAKE_WITH_CONVERSION_NODE || ConnectionResponse.Response == CONNECT_RESPONSE_MAKE_WITH_PROMOTION)
{
ConnectionResponse.Response = CONNECT_RESPONSE_DISALLOW;
}
return ConnectionResponse;
}
};