Skip to content

Commit

Permalink
fix(gestures): precise seeking setting in horizontal gesture
Browse files Browse the repository at this point in the history
kind of sloppy from me to forget about this
  • Loading branch information
abdallahmehiz committed Sep 9, 2024
1 parent 056fb0a commit 9bdd41b
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ fun GestureHandler(modifier: Modifier = Modifier) {
val brightnessGesture = playerPreferences.brightnessGesture.get()
val volumeGesture by playerPreferences.volumeGesture.collectAsState()
val seekGesture by playerPreferences.horizontalSeekGesture.collectAsState()
val preciseSeeking by playerPreferences.preciseSeeking.collectAsState()
val showSeekbarWhenSeeking by playerPreferences.showSeekBarWhenSeeking.collectAsState()
val doubleTapSeek: (Offset, IntSize) -> Unit = { offset, size ->
targetAlpha = 0.2f
Expand Down Expand Up @@ -228,7 +229,7 @@ fun GestureHandler(modifier: Modifier = Modifier) {
viewModel.gestureSeekAmount.update { _ ->
Pair(startingPosition, it - startingPosition)
}
viewModel.seekTo(it)
viewModel.seekTo(it, preciseSeeking)
}

if (showSeekbarWhenSeeking) viewModel.showSeekBar()
Expand Down

0 comments on commit 9bdd41b

Please sign in to comment.