# MotionEventCompat

Artifact: [androidx.core:core](https://developer.android.com/jetpack/androidx/releases/core) [View Source](https://cs.android.com/search?q=file:androidx/core/view/MotionEventCompat.java+class:androidx.core.view.MotionEventCompat) Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

*** ** * ** ***


```
public final class MotionEventCompat
```

<br />

*** ** * ** ***

Helper for accessing features in `https://developer.android.com/reference/android/view/MotionEvent.html`.

## Summary

| ### Constants |
|---|---|
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_HOVER_ENTER() = 9` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_ENTER` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_HOVER_EXIT() = 10` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_EXIT` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_HOVER_MOVE() = 7` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_MOVE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_MASK() = 255` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_MASK` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_POINTER_DOWN() = 5` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_DOWN` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_POINTER_INDEX_MASK() = 65280` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_MASK` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_POINTER_INDEX_SHIFT() = 8` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_SHIFT` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_POINTER_UP() = 6` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_UP` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_SCROLL() = 8` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_SCROLL` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_BRAKE() = 23` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_BRAKE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_DISTANCE() = 24` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_DISTANCE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GAS() = 22` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GAS` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_1() = 32` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_1` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_10() = 41` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_10` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_11() = 42` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_11` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_12() = 43` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_12` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_13() = 44` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_13` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_14() = 45` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_14` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_15() = 46` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_15` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_16() = 47` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_16` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_2() = 33` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_2` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_3() = 34` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_3` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_4() = 35` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_4` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_5() = 36` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_5` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_6() = 37` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_6` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_7() = 38` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_7` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_8() = 39` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_8` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_GENERIC_9() = 40` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_9` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_HAT_X() = 15` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_X` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_HAT_Y() = 16` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_Y` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_HSCROLL() = 10` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HSCROLL` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_LTRIGGER() = 17` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_LTRIGGER` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_ORIENTATION() = 8` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_ORIENTATION` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_PRESSURE() = 2` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_PRESSURE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RELATIVE_X() = 27` Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RELATIVE_X`. |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RELATIVE_Y() = 28` Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RELATIVE_Y`. |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RTRIGGER() = 18` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RTRIGGER` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RUDDER() = 20` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RUDDER` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RX() = 12` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RX` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RY() = 13` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RY` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_RZ() = 14` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RZ` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_SCROLL() = 26` Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_SCROLL`. |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_SIZE() = 3` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_SIZE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_THROTTLE() = 19` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_THROTTLE` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_TILT() = 25` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TILT` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_TOOL_MAJOR() = 6` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MAJOR` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_TOOL_MINOR() = 7` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MINOR` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_TOUCH_MAJOR() = 4` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MAJOR` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_TOUCH_MINOR() = 5` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MINOR` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_VSCROLL() = 9` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_VSCROLL` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_WHEEL() = 21` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_WHEEL` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_X() = 0` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_X` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_Y() = 1` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Y` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_Z() = 11` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Z` directly. <br /> |
| `static final int` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#BUTTON_PRIMARY() = 1` **This field is deprecated.** Use `https://developer.android.com/reference/android/view/MotionEvent.html#BUTTON_PRIMARY` directly. <br /> |

| ### Public methods |
|---|---|
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.findPointerIndex(pointerId)") [findPointerIndex](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#findPointerIndex(android.view.MotionEvent,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int pointerId)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#findPointerIndex(int)` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getActionIndex()") [getActionIndex](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getActionIndex(android.view.MotionEvent))(https://developer.android.com/reference/android/view/MotionEvent.html event)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getActionIndex()` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getActionMasked()") [getActionMasked](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getActionMasked(android.view.MotionEvent))(https://developer.android.com/reference/android/view/MotionEvent.html event)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAction()` directly. <br /> |
| `static float` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getAxisValue(axis)") [getAxisValue](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getAxisValue(android.view.MotionEvent,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int axis)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAxisValue(int)` directly. <br /> |
| `static float` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getAxisValue(axis, pointerIndex)") [getAxisValue](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getAxisValue(android.view.MotionEvent,int,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int axis, int pointerIndex)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAxisValue(int, int)` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getButtonState()") [getButtonState](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getButtonState(android.view.MotionEvent))(https://developer.android.com/reference/android/view/MotionEvent.html event)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getButtonState()` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getPointerCount()") [getPointerCount](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerCount(android.view.MotionEvent))(https://developer.android.com/reference/android/view/MotionEvent.html event)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getPointerCount()` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getPointerId(pointerIndex)") [getPointerId](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerId(android.view.MotionEvent,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int pointerIndex)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getPointerId(int)` directly. <br /> |
| `static int` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getSource()") [getSource](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getSource(android.view.MotionEvent))(https://developer.android.com/reference/android/view/MotionEvent.html event)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getSource()` directly. <br /> |
| `static float` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getX(pointerIndex)") [getX](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getX(android.view.MotionEvent,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int pointerIndex)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getX()` directly. <br /> |
| `static float` | `@https://developer.android.com/reference/androidx/annotation/ReplaceWith(expression = "event.getY(pointerIndex)") [getY](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getY(android.view.MotionEvent,int))(https://developer.android.com/reference/android/view/MotionEvent.html event, int pointerIndex)` **This method is deprecated.** Call `https://developer.android.com/reference/android/view/MotionEvent.html#getY()` directly. <br /> |
| `static boolean` | `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#isFromSource(android.view.MotionEvent,int)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/view/MotionEvent.html event, int source)` Determines whether the event is from the given source. |

## Constants

### ACTION_HOVER_ENTER

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_HOVER_ENTER = 9
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_ENTER` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_ENTER`.

### ACTION_HOVER_EXIT

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_HOVER_EXIT = 10
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_EXIT` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_EXIT`.

### ACTION_HOVER_MOVE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_HOVER_MOVE = 7
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_MOVE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_HOVER_MOVE`.

### ACTION_MASK

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_MASK = 255
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_MASK` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_MASK`.

### ACTION_POINTER_DOWN

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_POINTER_DOWN = 5
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_DOWN` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_DOWN`.

### ACTION_POINTER_INDEX_MASK

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_POINTER_INDEX_MASK = 65280
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_MASK` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_MASK`.

### ACTION_POINTER_INDEX_SHIFT

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_POINTER_INDEX_SHIFT = 8
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_SHIFT` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_INDEX_SHIFT`.

### ACTION_POINTER_UP

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_POINTER_UP = 6
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_UP` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_POINTER_UP`.

### ACTION_SCROLL

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int ACTION_SCROLL = 8
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_SCROLL` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#ACTION_SCROLL`.

### AXIS_BRAKE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_BRAKE = 23
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_BRAKE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_BRAKE`.

### AXIS_DISTANCE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_DISTANCE = 24
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_DISTANCE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_DISTANCE`.

### AXIS_GAS

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GAS = 22
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GAS` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GAS`.

### AXIS_GENERIC_1

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_1 = 32
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_1` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_1`.

### AXIS_GENERIC_10

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_10 = 41
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_10` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_10`.

### AXIS_GENERIC_11

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_11 = 42
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_11` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_11`.

### AXIS_GENERIC_12

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_12 = 43
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_12` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_12`.

### AXIS_GENERIC_13

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_13 = 44
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_13` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_13`.

### AXIS_GENERIC_14

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_14 = 45
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_14` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_14`.

### AXIS_GENERIC_15

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_15 = 46
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_15` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_15`.

### AXIS_GENERIC_16

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_16 = 47
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_16` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_16`.

### AXIS_GENERIC_2

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_2 = 33
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_2` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_2`.

### AXIS_GENERIC_3

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_3 = 34
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_3` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_3`.

### AXIS_GENERIC_4

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_4 = 35
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_4` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_4`.

### AXIS_GENERIC_5

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_5 = 36
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_5` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_5`.

### AXIS_GENERIC_6

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_6 = 37
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_6` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_6`.

### AXIS_GENERIC_7

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_7 = 38
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_7` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_7`.

### AXIS_GENERIC_8

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_8 = 39
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_8` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_8`.

### AXIS_GENERIC_9

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_GENERIC_9 = 40
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_9` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_GENERIC_9`.

### AXIS_HAT_X

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_HAT_X = 15
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_X` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_X`.

### AXIS_HAT_Y

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_HAT_Y = 16
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_Y` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HAT_Y`.

### AXIS_HSCROLL

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_HSCROLL = 10
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HSCROLL` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_HSCROLL`.

### AXIS_LTRIGGER

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_LTRIGGER = 17
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_LTRIGGER` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_LTRIGGER`.

### AXIS_ORIENTATION

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_ORIENTATION = 8
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_ORIENTATION` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_ORIENTATION`.

### AXIS_PRESSURE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_PRESSURE = 2
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_PRESSURE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_PRESSURE`.

### AXIS_RELATIVE_X

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RELATIVE_X = 27
```

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RELATIVE_X`.

### AXIS_RELATIVE_Y

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RELATIVE_Y = 28
```

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RELATIVE_Y`.

### AXIS_RTRIGGER

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RTRIGGER = 18
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RTRIGGER` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RTRIGGER`.

### AXIS_RUDDER

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RUDDER = 20
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RUDDER` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RUDDER`.

### AXIS_RX

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RX = 12
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RX` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RX`.

### AXIS_RY

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RY = 13
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RY` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RY`.

### AXIS_RZ

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_RZ = 14
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RZ` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_RZ`.

### AXIS_SCROLL

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_SCROLL = 26
```

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_SCROLL`.

### AXIS_SIZE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_SIZE = 3
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_SIZE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_SIZE`.

### AXIS_THROTTLE

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_THROTTLE = 19
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_THROTTLE` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_THROTTLE`.

### AXIS_TILT

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_TILT = 25
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TILT` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TILT`.

### AXIS_TOOL_MAJOR

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_TOOL_MAJOR = 6
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MAJOR` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MAJOR`.

### AXIS_TOOL_MINOR

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_TOOL_MINOR = 7
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MINOR` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOOL_MINOR`.

### AXIS_TOUCH_MAJOR

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_TOUCH_MAJOR = 4
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MAJOR` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MAJOR`.

### AXIS_TOUCH_MINOR

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_TOUCH_MINOR = 5
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MINOR` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_TOUCH_MINOR`.

### AXIS_VSCROLL

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_VSCROLL = 9
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_VSCROLL` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_VSCROLL`.

### AXIS_WHEEL

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_WHEEL = 21
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_WHEEL` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_WHEEL`.

### AXIS_X

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_X = 0
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_X` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_X`.

### AXIS_Y

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_Y = 1
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Y` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Y`.

### AXIS_Z

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int AXIS_Z = 11
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Z` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#AXIS_Z`.

### BUTTON_PRIMARY

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static final int BUTTON_PRIMARY = 1
```

> [!CAUTION]
> **This field is deprecated.**   
>
> Use `https://developer.android.com/reference/android/view/MotionEvent.html#BUTTON_PRIMARY` directly.

Synonym for `https://developer.android.com/reference/android/view/MotionEvent.html#BUTTON_PRIMARY`.

## Public methods

### findPointerIndex

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.findPointerIndex(pointerId)")
public static int [findPointerIndex](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#findPointerIndex(android.view.MotionEvent,int))(MotionEvent event, int pointerId)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#findPointerIndex(int)` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#findPointerIndex(int)`.

### getActionIndex

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getActionIndex()")
public static int [getActionIndex](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getActionIndex(android.view.MotionEvent))(MotionEvent event)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getActionIndex()` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAction()`, returning only the pointer index portion.

### getActionMasked

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getActionMasked()")
public static int [getActionMasked](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getActionMasked(android.view.MotionEvent))(MotionEvent event)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAction()` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAction()`, returning only the `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#ACTION_MASK()` portion.

### getAxisValue

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getAxisValue(axis)")
public static float [getAxisValue](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getAxisValue(android.view.MotionEvent,int))(MotionEvent event, int axis)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAxisValue(int)` directly. This method will be removed in a future release.

Get axis value for the first pointer index (may be an arbitrary pointer identifier).

| Parameters |
|---|---|
| `https://developer.android.com/reference/android/view/MotionEvent.html event` | motion event for which to get the value. |
| `int axis` | The axis identifier for the axis value to retrieve. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_X()` |   |
| `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_Y()` |   |

### getAxisValue

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getAxisValue(axis, pointerIndex)")
public static float [getAxisValue](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getAxisValue(android.view.MotionEvent,int,int))(MotionEvent event, int axis, int pointerIndex)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getAxisValue(int, int)` directly. This method will be removed in a future release.

Returns the value of the requested axis for the given pointer *index* (use `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerId(android.view.MotionEvent,int)` to find the pointer identifier for this index).

| Parameters |
|---|---|
| `https://developer.android.com/reference/android/view/MotionEvent.html event` | motion event for which to get the value. |
| `int axis` | The axis identifier for the axis value to retrieve. |
| `int pointerIndex` | Raw index of pointer to retrieve. Value may be from 0 (the first pointer that is down) to `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerCount(android.view.MotionEvent)`-1. |

| Returns |
|---|---|
| `float` | The value of the axis, or 0 if the axis is not available. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_X()` |   |
| `https://developer.android.com/reference/androidx/core/view/MotionEventCompat#AXIS_Y()` |   |

### getButtonState

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getButtonState()")
public static int [getButtonState](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getButtonState(android.view.MotionEvent))(MotionEvent event)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getButtonState()` directly. This method will be removed in a future release.

### getPointerCount

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getPointerCount()")
public static int [getPointerCount](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerCount(android.view.MotionEvent))(MotionEvent event)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getPointerCount()` directly. This method will be removed in a future release.

The number of pointers of data contained in this event. Always

### getPointerId

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getPointerId(pointerIndex)")
public static int [getPointerId](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getPointerId(android.view.MotionEvent,int))(MotionEvent event, int pointerIndex)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getPointerId(int)` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#getPointerId(int)`.

### getSource

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getSource()")
public static int [getSource](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getSource(android.view.MotionEvent))(MotionEvent event)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getSource()` directly. This method will be removed in a future release.

Gets the source of the event.

| Returns |
|---|---|
| `int` | The event source or `https://developer.android.com/reference/androidx/core/view/InputDeviceCompat#SOURCE_UNKNOWN()` if unknown. |

### getX

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getX(pointerIndex)")
public static float [getX](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getX(android.view.MotionEvent,int))(MotionEvent event, int pointerIndex)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getX()` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#getX(int)`.

### getY

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0) Deprecated in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
@ReplaceWith(expression = "event.getY(pointerIndex)")
public static float [getY](https://developer.android.com/reference/androidx/core/view/MotionEventCompat#getY(android.view.MotionEvent,int))(MotionEvent event, int pointerIndex)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Call `https://developer.android.com/reference/android/view/MotionEvent.html#getY()` directly. This method will be removed in a future release.

Call `https://developer.android.com/reference/android/view/MotionEvent.html#getY(int)`.

### isFromSource

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/core#1.1.0)

```
public static boolean isFromSource(@NonNull MotionEvent event, int source)
```

Determines whether the event is from the given source.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/view/MotionEvent.html event` | motion event for which to check the source. |
| `int source` | The input source to check against. |

| Returns |
|---|---|
| `boolean` | Whether the event is from the given source. |