Skip to content

Commit

Permalink
Merge pull request #49 from futuredapp/feature/disable-drag-up-comple…
Browse files Browse the repository at this point in the history
…tely

Disable dragUp activity completely when dragUpEnabled is set to…
  • Loading branch information
skywall authored Aug 11, 2021
2 parents 7da9585 + 806a2db commit 99623b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/kotlin/app/futured/hauler/HaulerView.kt
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class HaulerView @JvmOverloads constructor(
}

override fun onNestedScroll(target: View, dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int) {
if (isDragEnabled.not()) {
if (isDragEnabled.not() || (dragUpEnabled.not() && dyUnconsumed > 0)) {
return super.onNestedScroll(target, dxConsumed, dyConsumed, dxUnconsumed, dyUnconsumed)
}
dragScale(dyUnconsumed)
Expand Down

0 comments on commit 99623b5

Please sign in to comment.