Simplify conditional by initializing vol/pan to defaults
This commit is contained in:
@@ -2077,8 +2077,8 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me )
|
||||
|
||||
// determine what volume/panning to set note to
|
||||
// if middle-click, set to defaults
|
||||
volume_t vol;
|
||||
panning_t pan;
|
||||
volume_t vol = DefaultVolume;
|
||||
panning_t pan = DefaultPanning;
|
||||
|
||||
if( me->buttons() & Qt::LeftButton )
|
||||
{
|
||||
@@ -2093,11 +2093,6 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me )
|
||||
( (float)( PanningRight - PanningLeft ) ),
|
||||
PanningLeft, PanningRight);
|
||||
}
|
||||
else
|
||||
{
|
||||
vol = DefaultVolume;
|
||||
pan = DefaultPanning;
|
||||
}
|
||||
|
||||
if( m_noteEditMode == NoteEditVolume )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user