UKismetInputLibrary::PointerEvent_GetTouchpadIndex
#include "Kismet/KismetInputLibrary.h"
Access: public
Specifiers: staticBlueprintPure
Description
Returns which touchpad generated this event, for platforms and controllers that expose more than one touch surface per user.
Caveats & Gotchas
- • Meaningless on most platforms with a single touch surface or none at all — always 0 unless you're targeting hardware with multiple touchpads per controller.
- • Not the same as the finger/pointer index — use PointerEvent_GetPointerIndex to distinguish simultaneous touches on the same pad.
Signature
static int32 PointerEvent_GetTouchpadIndex(const FPointerEvent& Input); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| Input | const FPointerEvent& | The pointer event to read the touchpad index from. | — |
Return Type
int32 Example
Route touch input to the correct pad C++
FReply UMyWidget::NativeOnTouchStarted(const FGeometry& InGeometry, const FPointerEvent& InTouchEvent)
{
const int32 TouchpadIndex = UKismetInputLibrary::PointerEvent_GetTouchpadIndex(InTouchEvent);
RouteTouchToPad(TouchpadIndex, InTouchEvent);
return FReply::Handled();
} See Also
Tags
Version History
Introduced in: unknown
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?