DefaultRotaryHapticHandler
class DefaultRotaryHapticHandler(scrollableState: ScrollableState, hapticsChannel: Channel<RotaryHapticsType>, hapticsThresholdPx: Long = 50) : RotaryHapticHandler
Default implementation of RotaryHapticHandler. It handles haptic feedback based on the scrollableState, scrolled pixels and hapticsThresholdPx. Haptic is not fired in this class, instead it's sent to hapticsChannel where it'll performed later.
Parameters
scrollableState
Haptic performed based on this state
hapticsChannel
Channel to which haptic events will be sent
hapticsThresholdPx
A scroll threshold after which haptic is produced.
Constructors
Link copied to clipboard
constructor(scrollableState: ScrollableState, hapticsChannel: Channel<RotaryHapticsType>, hapticsThresholdPx: Long = 50)