UClickDragTool

[UClickDragTool](API\Runtime\InteractiveToolsFramework\BaseTools\UClickDragTool) is a base tool that basically just implements [IClickDragBehaviorTarget](API\Runtime\InteractiveToolsFramework\BaseBehaviors\IClickDragBehaviorTarget), and on setup registers a [UClickDragInputBehavior](API\Runtime\InteractiveToolsFramework\BaseBehaviors\UClickDragInputBehavior).

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

InteractiveToolsFramework

Header

/Engine/Source/Runtime/InteractiveToolsFramework/Public/BaseTools/ClickDragTool.h

Include

#include "BaseTools/ClickDragTool.h"

Syntax

class UClickDragTool :
    public UInteractiveTool,
    public IClickDragBehaviorTarget

Remarks

UClickDragTool is a base tool that basically just implements IClickDragBehaviorTarget, and on setup registers a UClickDragInputBehavior. You can subclass this Tool to implement basic click-drag type Tools. If you want to do more advanced things, like handle modifier buttons/keys, you will need to implement IClickDragBehaviorTarget yourself

Overridden from UInteractiveTool

Name Description

Public function Virtual

void

 

Setup()

Register default primary-button-click InputBehaviors

Overridden from IClickDragBehaviorTarget

Name Description

Public function Virtual

FInputRayHit

 

CanBeginClickDragSequence

(
    const FInputDeviceRay& PressPos
)

IClickBehaviorTarget implementation Test if target can begin click-drag interaction at this point

Public function Virtual

void

 

OnClickDrag

(
    const FInputDeviceRay& DragPos
)

Notify Target that input position has changed

Public function Virtual

void

 

OnClickPress

(
    const FInputDeviceRay& PressPos
)

Notify Target that click press ocurred

Public function Virtual

void

 

OnClickRelease

(
    const FInputDeviceRay& ReleasePos
)

Notify Target that click release occurred

Public function Virtual

void

 

OnTerminateDragSequence()

Notify Target that click-drag sequence has been explicitly terminated (eg by escape key)