Added in [API level 3](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Methods](https://developer.android.com/reference/android/view/GestureDetector.OnDoubleTapListener#pubmethods)

# GestureDetector.OnDoubleTapListener

*** ** * ** ***

` public static interface GestureDetector.OnDoubleTapListener `   
` `

|---|
| android.view.GestureDetector.OnDoubleTapListener |

Known indirect subclasses [GestureDetector.SimpleOnGestureListener](https://developer.android.com/reference/android/view/GestureDetector.SimpleOnGestureListener) [GestureDetector.SimpleOnGestureListener](https://developer.android.com/reference/android/view/GestureDetector.SimpleOnGestureListener) A convenience class to extend when you only want to listen for a subset of all the gestures.   

*** ** * ** ***

The listener that is used to notify when a double-tap or a confirmed single-tap occur.

## Summary

| ### Public methods ||
|---|---|
| ` abstract boolean` | ` https://developer.android.com/reference/android/view/GestureDetector.OnDoubleTapListener#onDoubleTap(android.view.MotionEvent)(https://developer.android.com/reference/android/view/MotionEvent e) ` Notified when a double-tap occurs. |
| ` abstract boolean` | ` https://developer.android.com/reference/android/view/GestureDetector.OnDoubleTapListener#onDoubleTapEvent(android.view.MotionEvent)(https://developer.android.com/reference/android/view/MotionEvent e) ` Notified when an event within a double-tap gesture occurs, including the down, move, and up events. |
| ` abstract boolean` | ` https://developer.android.com/reference/android/view/GestureDetector.OnDoubleTapListener#onSingleTapConfirmed(android.view.MotionEvent)(https://developer.android.com/reference/android/view/MotionEvent e) ` Notified when a single-tap occurs. |

## Public methods

### onDoubleTap

Added in [API level 3](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract boolean onDoubleTap (MotionEvent e)
```

Notified when a double-tap occurs. Triggered on the down event of second tap.

<br />

| Parameters ||
|---|---|
| `e` | `MotionEvent`: The down motion event of the first tap of the double-tap. This value cannot be `null`. <br /> |

| Returns ||
|---|---|
| `boolean` | true if the event is consumed, else false <br /> |

### onDoubleTapEvent

Added in [API level 3](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract boolean onDoubleTapEvent (MotionEvent e)
```

Notified when an event within a double-tap gesture occurs, including the down, move, and up events.

<br />

| Parameters ||
|---|---|
| `e` | `MotionEvent`: The motion event that occurred during the double-tap gesture. This value cannot be `null`. <br /> |

| Returns ||
|---|---|
| `boolean` | true if the event is consumed, else false <br /> |

### onSingleTapConfirmed

Added in [API level 3](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract boolean onSingleTapConfirmed (MotionEvent e)
```

Notified when a single-tap occurs.

Unlike `https://developer.android.com/reference/android/view/GestureDetector.OnGestureListener#onSingleTapUp(android.view.MotionEvent)`, this will only be called after the detector is confident that the user's first tap is not followed by a second tap leading to a double-tap gesture.

<br />

| Parameters ||
|---|---|
| `e` | `MotionEvent`: The down motion event of the single-tap. This value cannot be `null`. <br /> |

| Returns ||
|---|---|
| `boolean` | true if the event is consumed, else false <br /> |