From da1a1949b36605ef031c9b4697af019c768b2b2c Mon Sep 17 00:00:00 2001 From: Juha Heinanen Date: Sun, 6 Apr 2025 10:08:39 +0300 Subject: [PATCH] Renamed variable --- app/src/main/kotlin/com/tutpro/baresip/CustomElements.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/kotlin/com/tutpro/baresip/CustomElements.kt b/app/src/main/kotlin/com/tutpro/baresip/CustomElements.kt index ee5369d4..bba968c9 100644 --- a/app/src/main/kotlin/com/tutpro/baresip/CustomElements.kt +++ b/app/src/main/kotlin/com/tutpro/baresip/CustomElements.kt @@ -235,11 +235,11 @@ object CustomElements { val contentHeight = state.maxValue + viewHeight val scrollbarHeight = (viewHeight * (viewHeight / contentHeight )).coerceIn(10.dp.toPx() .. viewHeight) val variableZone = viewHeight - scrollbarHeight - val scrollbarYoffset = (state.value.toFloat() / state.maxValue) * variableZone + val scrollbarOffsetY = (state.value.toFloat() / state.maxValue) * variableZone drawRoundRect( cornerRadius = CornerRadius(scrollbarWidth.toPx() / 2, scrollbarWidth.toPx() / 2), color = color, - topLeft = Offset(this.size.width - scrollbarWidth.toPx(), scrollbarYoffset), + topLeft = Offset(this.size.width - scrollbarWidth.toPx(), scrollbarOffsetY), size = Size(scrollbarWidth.toPx(), scrollbarHeight), alpha = alpha )