Files
UnrealEngineUWP/Engine/Source/Runtime/InteractiveToolsFramework/Private/InteractionMechanic.cpp
michael balzer 5a20a5e3d0 Move InteractiveToolsFramework and GeometryFramework out of Experimental
#jira UETOOL-3823
#rb brooke.hubert
#preflight 6109d1e9b4288d0001acb7ef

#ROBOMERGE-SOURCE: CL 17055606 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v850-17047176)

[CL 17055619 by michael balzer in ue5-release-engine-test branch]
2021-08-04 13:59:17 -04:00

57 lines
1.0 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "InteractionMechanic.h"
UInteractionMechanic::UInteractionMechanic()
{
// undo/redo doesn't work on uproperties unless UObject is transactional
//SetFlags(RF_Transactional);
}
void UInteractionMechanic::Setup(UInteractiveTool* ParentToolIn)
{
ParentTool = ParentToolIn;
}
void UInteractionMechanic::Shutdown()
{
ParentTool = nullptr;
}
void UInteractionMechanic::Render(IToolsContextRenderAPI* RenderAPI)
{
}
void UInteractionMechanic::Tick(float DeltaTime)
{
}
UInteractiveTool* UInteractionMechanic::GetParentTool() const
{
return ParentTool.Get();
}
void UInteractionMechanic::AddToolPropertySource(UInteractiveToolPropertySet* PropertySet)
{
if (ParentTool.IsValid())
{
ParentTool->AddToolPropertySource(PropertySet);
}
}
bool UInteractionMechanic::SetToolPropertySourceEnabled(UInteractiveToolPropertySet* PropertySet, bool bEnabled)
{
if (ParentTool.IsValid())
{
return ParentTool->SetToolPropertySourceEnabled(PropertySet, bEnabled);
}
return false;
}