From 2eca8511cbcb9633649535d29cc0b06db9e2fe48 Mon Sep 17 00:00:00 2001 From: Semen <55978818+semenvav@users.noreply.github.com> Date: Sat, 24 Jun 2023 17:37:20 +0300 Subject: [PATCH] Trackers empty scores start starts from middle (#9624) * Trackers empty scores start starts from middle * Trackers empty scores start starts from middle * Trackers empty scores start starts from middle --- .../eu/kanade/presentation/track/TrackInfoDialogSelector.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/eu/kanade/presentation/track/TrackInfoDialogSelector.kt b/app/src/main/java/eu/kanade/presentation/track/TrackInfoDialogSelector.kt index c41f074023..53c985a6c6 100644 --- a/app/src/main/java/eu/kanade/presentation/track/TrackInfoDialogSelector.kt +++ b/app/src/main/java/eu/kanade/presentation/track/TrackInfoDialogSelector.kt @@ -123,7 +123,7 @@ fun TrackScoreSelector( content = { WheelTextPicker( modifier = Modifier.align(Alignment.Center), - startIndex = selections.indexOf(selection).coerceAtLeast(0), + startIndex = selections.indexOf(selection).takeIf { it > 0 } ?: (selections.size / 2), items = selections, onSelectionChanged = { onSelectionChange(selections[it]) }, )