diff --git a/ChangeLog b/ChangeLog index 2efd0f035..e3d6aad96 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2009-02-01 Andrew Kelley + + * src/core/track.cpp: + integrated pitanga's patch to fix unquantized BB dragging in + song editor. Changed ctrl modifier to alt to be consistent. + 2009-02-01 Andrew Kelley * plugins/flp_import/flp_import.cpp: diff --git a/src/core/track.cpp b/src/core/track.cpp index a48e3cb57..1c1882a3b 100644 --- a/src/core/track.cpp +++ b/src/core/track.cpp @@ -683,7 +683,7 @@ void trackContentObjectView::mouseMoveEvent( QMouseEvent * _me ) QVector so = m_trackView->getTrackContainerView()->selectedObjects(); QVector tcos; - midiTime smallest_pos; + midiTime smallest_pos, t; // find out smallest position of all selected objects for not // moving an object before zero for( QVector::iterator it = so.begin(); @@ -705,10 +705,15 @@ void trackContentObjectView::mouseMoveEvent( QMouseEvent * _me ) for( QVector::iterator it = tcos.begin(); it != tcos.end(); ++it ) { - ( *it )->movePosition( ( *it )->startPosition() + - static_cast( dx * - midiTime::ticksPerTact() / ppt ) - - smallest_pos ); + t = ( *it )->startPosition() + + static_cast( dx *midiTime::ticksPerTact() / + ppt )-smallest_pos; + if( ! ( _me->modifiers() & Qt::AltModifier ) + && _me->button() == Qt::NoButton ) + { + t = t.toNearestTact(); + } + ( *it )->movePosition( t ); } } else if( m_action == Resize )