Sdílet prostřednictvím


MotionEvent.GetPointerId(Int32) Method

Definition

Return the pointer identifier associated with a particular pointer data index in this event.

[Android.Runtime.Register("getPointerId", "(I)I", "")]
public int GetPointerId (int pointerIndex);
[<Android.Runtime.Register("getPointerId", "(I)I", "")>]
member this.GetPointerId : int -> int

Parameters

pointerIndex
Int32

Raw index of pointer to retrieve. Value may be from 0 (the first pointer that is down) to #getPointerCount()-1.

Returns

Attributes

Remarks

Return the pointer identifier associated with a particular pointer data index in this event. The identifier tells you the actual pointer number associated with the data, accounting for individual pointers going up and down since the start of the current gesture.

Java documentation for android.view.MotionEvent.getPointerId(int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to