Navigation
API > API/Runtime > API/Runtime/Slate > API/Runtime/Slate/Widgets > API/Runtime/Slate/Widgets/Input
Inheritance Hierarchy
- FSlateControlledConstruction
- TSharedFromThis
- SWidget
- SLeafWidget
- SVirtualJoystick
References
| Module | Slate |
| Header | /Engine/Source/Runtime/Slate/Public/Widgets/Input/SVirtualJoystick.h |
| Include | #include "Widgets/Input/SVirtualJoystick.h" |
Syntax
class SVirtualJoystick : public SLeafWidget
Remarks
A virtual joystsick
Variables
| Type | Name | Description | |
|---|---|---|---|
| float | ActivationDelay | ||
| float | ActiveOpacity | Global settings from the UTouchInterface | |
| uint32: 1 | bCenterOnEvent | If true, this zone will have it's "center" set when you touch it, otherwise the center will be set to the center of the zone | |
| uint32: 1 | bPreventReCenter | If true, ignore re-centering | |
| uint32: 1 | bVisible | True if the joystick should be visible | |
| TControlArray< FControlData > | Controls | List of controls set by the UTouchInterface | |
| float | Countdown | Countdown until next state change | |
| float | CurrentOpacity | Target opacity | |
| float | InactiveOpacity | ||
| float | PreviousScalingFactor | Last used scaling value for | |
| float | StartupDelay | ||
| EVirtualJoystickState | State | The current state of all controls | |
| float | TimeUntilDeactive | ||
| float | TimeUntilReset |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddControl
(
const FControlInfo& Control |
||
| void | AlignBoxIntoScreen
(
FVector2D& Position, |
||
| void | |||
| FVector2D | ComputeThumbPosition
(
int32 ControlIndex, |
||
| void | Construct
(
const FArguments& InArgs |
||
| float | Return the target opacity to lerp to given the current state | ||
| void | HandleDisplayMetricsChanged
(
const FDisplayMetrics& NewDisplayMetric |
Callback for handling display metrics changes. | |
| bool | HandleTouch
(
int32 ControlIndex, |
Process a touch event (on movement and possibly on initial touch) | |
| void | SetControls
(
const TArray< FControlInfo >& InControls |
||
| void | SetGlobalParameters
(
float InActiveOpacity, |
Sets parameters that control all controls | |
| void | SetJoystickVisibility
(
const bool bVisible, |
Shows or hides the controls (for instance during cinematics) | |
| bool | Static function to return if external users should create/activate/etc a touch interface Note that this function is also used internally, so even if this returns false but an SVirtualJoystick is created, it won't actually show any controls |
Overridden from SWidget
| Type | Name | Description | |
|---|---|---|---|
| FVector2D | ComputeDesiredSize
(
float |
Overwritten from SWidget. | |
| int32 | OnPaint
(
const FPaintArgs& Args, |
Overwritten from SWidget. | |
| FReply | OnTouchEnded
(
const FGeometry& MyGeometry, |
Called when a touchpad touch is ended (finger lifted) | |
| FReply | OnTouchMoved
(
const FGeometry& MyGeometry, |
Called when a touchpad touch is moved (finger moved) | |
| FReply | OnTouchStarted
(
const FGeometry& MyGeometry, |
Called when a touchpad touch is started (finger down) | |
| bool | Checks to see if this widget supports keyboard focus. Override this in derived classes. | ||
| void | Ticks this widget with Geometry. |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FArguments | |||
| FControlData | The settings and current state of each zone we render | ||
| FControlInfo | The settings of each zone we render |
Enums
| Type | Name | Description | |
|---|---|---|---|
| EVirtualJoystickState |
Typedefs
| Name | Description |
|---|---|
| TControlArray | TArray specialization for controls. |