Add Compose lint checks

Still need to address most of them though.
This commit is contained in:
arkon
2023-11-11 18:13:44 -05:00
parent 402e2c47fb
commit cb67f1de52
22 changed files with 57 additions and 26 deletions

View File

@@ -75,8 +75,8 @@ fun SetIntervalDialog(
}
}
WheelTextPicker(
size = size,
items = items,
size = size,
startIndex = selectedInterval,
onSelectionChanged = { selectedInterval = it },
)

View File

@@ -102,9 +102,9 @@ fun TrackChapterSelector(
title = stringResource(R.string.chapters),
content = {
WheelNumberPicker(
items = range.toList(),
modifier = Modifier.align(Alignment.Center),
startIndex = selection,
items = range.toList(),
onSelectionChanged = { onSelectionChange(it) },
)
},
@@ -125,9 +125,9 @@ fun TrackScoreSelector(
title = stringResource(R.string.score),
content = {
WheelTextPicker(
items = selections,
modifier = Modifier.align(Alignment.Center),
startIndex = selections.indexOf(selection).takeIf { it > 0 } ?: (selections.size / 2),
items = selections,
onSelectionChanged = { onSelectionChange(selections[it]) },
)
},