From a0212bd2cdbe14d75ec3d919f057e88fc1e09b8a Mon Sep 17 00:00:00 2001 From: Mudar Noufal Date: Thu, 14 Dec 2017 16:22:55 -0500 Subject: [PATCH] Fixed issue #67, drag to min/max positions --- SeekArc_library/src/com/triggertrap/seekarc/SeekArc.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SeekArc_library/src/com/triggertrap/seekarc/SeekArc.java b/SeekArc_library/src/com/triggertrap/seekarc/SeekArc.java index 09c881d..7792634 100644 --- a/SeekArc_library/src/com/triggertrap/seekarc/SeekArc.java +++ b/SeekArc_library/src/com/triggertrap/seekarc/SeekArc.java @@ -409,9 +409,9 @@ private double getTouchDegrees(float xPos, float yPos) { private int getProgressForAngle(double angle) { int touchProgress = (int) Math.round(valuePerDegree() * angle); - touchProgress = (touchProgress < 0) ? INVALID_PROGRESS_VALUE + touchProgress = (touchProgress < 0) ? 0 : touchProgress; - touchProgress = (touchProgress > mMax) ? INVALID_PROGRESS_VALUE + touchProgress = (touchProgress > mMax) ? mMax : touchProgress; return touchProgress; }