disabled note volume editing while dragging a selection
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@1891 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
|
||||
* src/gui/piano_roll.cpp:
|
||||
ability to scroll left and right while using ctrl to select notes
|
||||
disabled volume bar changes while dragging a selection
|
||||
|
||||
2008-12-08 Tobias Doerffel <tobydox/at/users/dot/sourceforge/dot/net>
|
||||
|
||||
|
||||
@@ -1574,8 +1574,10 @@ void pianoRoll::mouseMoveEvent( QMouseEvent * _me )
|
||||
|
||||
if( _me->y() > PR_TOP_MARGIN )
|
||||
{
|
||||
bool edit_note = ( _me->y() > height() -
|
||||
PR_BOTTOM_MARGIN - m_notesEditHeight );
|
||||
bool edit_note = ( _me->y() >
|
||||
height() - PR_BOTTOM_MARGIN - m_notesEditHeight )
|
||||
&& m_action != ActionSelectNotes;
|
||||
|
||||
|
||||
int key_num = getKey( _me->y() );
|
||||
int x = _me->x();
|
||||
@@ -1612,16 +1614,18 @@ void pianoRoll::mouseMoveEvent( QMouseEvent * _me )
|
||||
}
|
||||
x -= WHITE_KEY_WIDTH;
|
||||
|
||||
// Volume Bars
|
||||
if( _me->buttons() & Qt::LeftButton
|
||||
&& m_editMode == ModeDraw
|
||||
&& (m_action == ActionMoveNote || m_action == ActionResizeNote ) )
|
||||
{
|
||||
// handle moving notes and resizing them
|
||||
dragNotes(_me->x(), _me->y(), _me->modifiers() & Qt::AltModifier);
|
||||
}
|
||||
else if( ( edit_note == true || m_action == ActionChangeNoteVolume ) &&
|
||||
_me->buttons() & Qt::LeftButton )
|
||||
{
|
||||
// Volume Bars
|
||||
|
||||
// Use nearest-note when changing volume so the bars can
|
||||
// be "scribbled"
|
||||
int pos_ticks = ( x * midiTime::ticksPerTact() ) /
|
||||
|
||||
Reference in New Issue
Block a user