onTapDetected
fun onTapDetected(x: Float, viewWidth: Int, isLocked: Boolean, onSingleTap: () -> Unit): Boolean(source)
Call when a valid tap is detected (short hold, minimal movement, valid touch area). Routes to double-tap seeking/pausing or schedules a delayed single-tap callback.
Updates lastTouchEndTime when a confirmed tap (single or double) is recorded.
Return
true if a double-tap action was performed.
Parameters
x
X coordinate of the tap in the view's coordinate space.
viewWidth
Width of the view (used to compute left/center/right zones).
isLocked
Whether player controls are locked (suppresses double-tap seek).
onSingleTap
Invoked when it is determined to be a single tap; may be deferred.