diff --git a/swiper/build.gradle.kts b/swiper/build.gradle.kts index cf7dc23..3be7d79 100644 --- a/swiper/build.gradle.kts +++ b/swiper/build.gradle.kts @@ -45,8 +45,7 @@ afterEvaluate { create("release") { groupId = "moe.tlaster" artifactId = "swiper" - version = "0.8.0" - + version = "0.8.1" from(components["release"]) } } diff --git a/swiper/src/main/java/moe/tlaster/swiper/SwiperState.kt b/swiper/src/main/java/moe/tlaster/swiper/SwiperState.kt index c786831..a0493c1 100644 --- a/swiper/src/main/java/moe/tlaster/swiper/SwiperState.kt +++ b/swiper/src/main/java/moe/tlaster/swiper/SwiperState.kt @@ -85,7 +85,7 @@ class SwiperState( internal suspend fun fling(velocity: Float) { val value = _offset.value val calcCurrentHeight = abs(value) / 1000 - if(velocity.absoluteValue == 0.0f && calcCurrentHeight > dismissHeight){ + if(velocity.absoluteValue >= 0.0f && calcCurrentHeight > dismissHeight){ when { _direction == Direction.Up && value < 0.0 -> { dismiss(velocity)