Navigation
API > API/Runtime > API/Runtime/InteractiveToolsFramework
USingleKeyCaptureBehavior captures a key press and routes it to target via the IModifierToggleBehaviorTarget interface. If you want similar behavior without actually capturing the key, you should use UKeyAsModifierInputBehavior.
| Name | USingleKeyCaptureBehavior |
| Type | class |
| Header File | /Engine/Source/Runtime/InteractiveToolsFramework/Public/BaseBehaviors/SingleKeyCaptureBehavior.h |
| Include Path | #include "BaseBehaviors/SingleKeyCaptureBehavior.h" |
Syntax
UCLASS (MinimalAPI)
class USingleKeyCaptureBehavior : public UInputBehavior
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UInputBehavior → USingleKeyCaptureBehavior
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
USingleKeyCaptureBehavior() |
BaseBehaviors/SingleKeyCaptureBehavior.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| ModifierCheckFunc | TFunction< bool(const FInputDeviceState &)> | WantsCapture() will only return capture request if this function returns true (or is null) Intended to be used for alt/ctrl/cmd/shift modifiers on the main key | BaseBehaviors/SingleKeyCaptureBehavior.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void Initialize
(
IModifierToggleBehaviorTarget* Target, |
Initialize this behavior with the given Target. | BaseBehaviors/SingleKeyCaptureBehavior.h |
Overridden from UInputBehavior
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual FInputCaptureUpdate BeginCapture
(
const FInputDeviceState& InputState, |
Called after WantsCapture() returns a capture request that was accepted | BaseBehaviors/SingleKeyCaptureBehavior.h | |
virtual void ForceEndCapture
(
const FInputCaptureData& CaptureData |
If this is called, the Behavior has forcibly lost capture (eg due to app losing focus for example) and needs to clean up accordingly | BaseBehaviors/SingleKeyCaptureBehavior.h | |
virtual EInputDevices GetSupportedDevices() |
Which device types does this Behavior support | BaseBehaviors/SingleKeyCaptureBehavior.h | |
virtual FInputCaptureUpdate UpdateCapture
(
const FInputDeviceState& InputState, |
Called for each new input event during a capture sequence. | BaseBehaviors/SingleKeyCaptureBehavior.h | |
virtual FInputCaptureRequest WantsCapture
(
const FInputDeviceState& InputState |
Given the input state, does this Behavior want to begin capturing some input devices? | BaseBehaviors/SingleKeyCaptureBehavior.h |