Skip to content

Commit

Permalink
fix: Properly constrain slider widget scroll range
Browse files Browse the repository at this point in the history
  • Loading branch information
lucyydotp committed Oct 23, 2023
1 parent 32e0df3 commit a9f9614
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public class SliderWidget(


override fun mouseScrolled(d: Double, e: Double, f: Double): Boolean {
currentIndex = (currentIndex + sign(f).toInt()).coerceIn(min..max)
currentIndex = (currentIndex + sign(f).toInt()).coerceIn(offsets.indices)
return true
}

Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
allprojects {
group = "com.noxcrew.sheeplib"
version = "1.0.0"
version = "1.0.1"
}

0 comments on commit a9f9614

Please sign in to comment.