fix: volume/brightness gesture triggering when hold to speed is active

Fixes #992
This commit is contained in:
tapframe 2026-05-09 01:02:13 +05:30
parent 4ca66bc385
commit a6f8041c9e

View file

@ -1449,12 +1449,15 @@ fun PlayerScreen(
totalDy += delta.y
if (gestureMode == null) {
val holdToSpeedActive = isHoldToSpeedGestureActiveState.value
val horizontalDominant =
!isHoldToSpeedGestureActiveState.value &&
!holdToSpeedActive &&
abs(totalDx) > viewConfiguration.touchSlop &&
abs(totalDx) > abs(totalDy)
val verticalDominant =
abs(totalDy) > viewConfiguration.touchSlop && abs(totalDy) > abs(totalDx)
!holdToSpeedActive &&
abs(totalDy) > viewConfiguration.touchSlop &&
abs(totalDy) > abs(totalDx)
gestureMode = when {
horizontalDominant -> {