diff options
author | Jan Holthuis <jan.holthuis@ruhr-uni-bochum.de> | 2020-09-25 22:47:55 +0200 |
---|---|---|
committer | Jan Holthuis <jan.holthuis@ruhr-uni-bochum.de> | 2020-09-25 22:47:55 +0200 |
commit | 5546a42a923335b9c2b8c635232bb70fb406b56c (patch) | |
tree | 8cbd40eaea4ac2aa7096a9edbdc95b394c466e20 | |
parent | 400817e7280fd98102512c4739050e28129369cb (diff) |
engine/vinylcontrolcontrol: Fix precision loss (wrong use of int)
-rw-r--r-- | src/engine/vinylcontrolcontrol.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/engine/vinylcontrolcontrol.cpp b/src/engine/vinylcontrolcontrol.cpp index 31248dd494..940d08bd79 100644 --- a/src/engine/vinylcontrolcontrol.cpp +++ b/src/engine/vinylcontrolcontrol.cpp @@ -117,7 +117,7 @@ void VinylControlControl::slotControlVinylSeek(double fractionalPos) { } double shortest_distance = 0; - int nearest_playpos = -1; + double nearest_playpos = -1; const QList<CuePointer> cuePoints(pTrack->getCuePoints()); QListIterator<CuePointer> it(cuePoints); @@ -127,7 +127,7 @@ void VinylControlControl::slotControlVinylSeek(double fractionalPos) { continue; } - int cue_position = pCue->getPosition(); + double cue_position = pCue->getPosition(); // pick cues closest to new_playpos if ((nearest_playpos == -1) || (fabs(new_playpos - cue_position) < shortest_distance)) { |