diff --git a/src/tracks/ui/SelectHandle.cpp b/src/tracks/ui/SelectHandle.cpp index a7836f6b7..62ed236b7 100644 --- a/src/tracks/ui/SelectHandle.cpp +++ b/src/tracks/ui/SelectHandle.cpp @@ -493,12 +493,14 @@ void SelectHandle::SetUseSnap(bool use) // Repaint to turn the snap lines on or off mChangeHighlight = RefreshCode::RefreshAll; - if (hasSnap && IsClicked()) + if (IsClicked()) { // Readjust the moving selection end AssignSelection( ::GetActiveProject()->GetViewInfo(), mUseSnap ? mSnapEnd.outTime : mSnapEnd.timeSnappedTime, nullptr); + mChangeHighlight |= RefreshCode::UpdateSelection; + } } bool SelectHandle::HasSnap() const @@ -631,8 +633,7 @@ UIHandle::Result SelectHandle::Click mFreqSelMode = FREQ_SEL_INVALID; #endif mSelStartValid = true; - if (!(mUseSnap && mSnapStart.Snapped())) - mSelStart = value; + mSelStart = value; AdjustSelection(pProject, viewInfo, event.m_x, mRect.x, pTrack); break; } @@ -727,8 +728,7 @@ UIHandle::Result SelectHandle::Click mFreqSelMode = FREQ_SEL_INVALID; #endif mSelStartValid = true; - if (!(mUseSnap && mSnapStart.Snapped())) - mSelStart = value; + mSelStart = value; break; #ifdef EXPERIMENTAL_SPECTRAL_EDITING case SBBottom: @@ -1178,9 +1178,9 @@ void SelectHandle::AdjustSelection // using snap-to-time -- then we always accept the snap results) if (mSnapStart.outCoord >= 0 && mSnapEnd.outCoord >= 0 && - std::abs(mSnapStart.outCoord - mSnapEnd.outCoord) < 3 && - !mSnapEnd.snappedTime) { - selend = origSelend; + std::abs(mSnapStart.outCoord - mSnapEnd.outCoord) < 3) { + if(!mSnapEnd.snappedTime) + selend = origSelend; mSnapEnd.outCoord = -1; } }