Navigation
API > API/Runtime > API/Runtime/InteractiveToolsFramework > API/Runtime/InteractiveToolsFramework/BaseBehaviors
Inheritance Hierarchy
- UObject
- UInputBehavior
- USingleKeyCaptureBehavior
References
| Module | InteractiveToolsFramework |
| Header | /Engine/Source/Runtime/InteractiveToolsFramework/Public/BaseBehaviors/SingleKeyCaptureBehavior.h |
| Include | #include "BaseBehaviors/SingleKeyCaptureBehavior.h" |
Syntax
UCLASS (MinimalAPI)
class USingleKeyCaptureBehavior : public UInputBehavior
Remarks
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.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TFunction< bool(const FInputDeviceState &)> | ModifierCheckFunc | 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 | |
| FKey | ModifierKey | Key that is used as modifier | |
| FInputBehaviorModifierStates | Modifiers | Modifier set for this behavior, internally initialized with check on ModifierKey | |
| FKey | PressedButton | The key that was pressed to activate capture | |
| IModifierToggleBehaviorTarget * | Target | Modifier Target object |
Constructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Initialize
(
IModifierToggleBehaviorTarget* Target, |
Initialize this behavior with the given Target. |
Overridden from UInputBehavior
| Type | Name | Description | |
|---|---|---|---|
| FInputCaptureUpdate | BeginCapture
(
const FInputDeviceState& InputState, |
Called after WantsCapture() returns a capture request that was accepted | |
| 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 | |
| EInputDevices | Which device types does this Behavior support | ||
| FInputCaptureUpdate | UpdateCapture
(
const FInputDeviceState& InputState, |
Called for each new input event during a capture sequence. | |
| FInputCaptureRequest | WantsCapture
(
const FInputDeviceState& InputState |
Given the input state, does this Behavior want to begin capturing some input devices? |