Android 12 Developer Preview is here! Try it out, and give us your feedback!

ViewConfiguration

interface ViewConfiguration
androidx.compose.ui.platform.ViewConfiguration

Contains methods to standard constants used in the UI for timeouts, sizes, and distances.

Summary

Properties
abstract Long

The minimum duration between the first tap's up event and the second tap's down event for an interaction to be considered a double-tap.

abstract Long

The duration between the first tap's up event and the second tap's down event for an interaction to be considered a double-tap.

abstract Long

The duration before a press turns into a long press.

abstract Float

Distance in pixels a touch can wander before we think the user is scrolling.

Properties

doubleTapMinTimeMillis

abstract val doubleTapMinTimeMillis: Long

The minimum duration between the first tap's up event and the second tap's down event for an interaction to be considered a double-tap.

doubleTapTimeoutMillis

abstract val doubleTapTimeoutMillis: Long

The duration between the first tap's up event and the second tap's down event for an interaction to be considered a double-tap.

longPressTimeoutMillis

abstract val longPressTimeoutMillis: Long

The duration before a press turns into a long press.

touchSlop

abstract val touchSlop: Float

Distance in pixels a touch can wander before we think the user is scrolling.