diff --git a/src/core/FxMixer.cpp b/src/core/FxMixer.cpp index 43a254660..7cf27b8c3 100644 --- a/src/core/FxMixer.cpp +++ b/src/core/FxMixer.cpp @@ -512,7 +512,7 @@ void FxMixer::saveSettings( QDomDocument & _doc, QDomElement & _this ) } } - +// make sure we have at least num channels void FxMixer::allocateChannelsTo(int num) { while( num > m_fxChannels.size() - 1 ) diff --git a/src/gui/FxMixerView.cpp b/src/gui/FxMixerView.cpp index 0cb3f1938..b61bcbf7b 100644 --- a/src/gui/FxMixerView.cpp +++ b/src/gui/FxMixerView.cpp @@ -196,14 +196,13 @@ void FxMixerView::refreshDisplay() chLayout->addWidget(m_fxChannelViews[i]->m_fxLine); } - // fix master -//TODO + updateMaxChannelSelector(); } +// update the and max. channel number for every instrument void FxMixerView::updateMaxChannelSelector() { - // update the and max. channel number for every instrument QVector songTrackList = engine::getSong()->tracks(); QVector bbTrackList = engine::getBBTrackContainer()->tracks(); @@ -439,6 +438,7 @@ void FxMixerView::setCurrentFxLine( int _line ) void FxMixerView::clear() { m_rackView->clearViews(); + refreshDisplay(); } diff --git a/src/tracks/InstrumentTrack.cpp b/src/tracks/InstrumentTrack.cpp index f56d6487b..252980448 100644 --- a/src/tracks/InstrumentTrack.cpp +++ b/src/tracks/InstrumentTrack.cpp @@ -103,13 +103,14 @@ InstrumentTrack::InstrumentTrack( trackContainer * _tc ) : this, tr( "Panning" ) ), m_pitchModel( 0, -100, 100, 1, this, tr( "Pitch" ) ), m_pitchRangeModel( 1, 1, 24, this, tr( "Pitch range" ) ), - m_effectChannelModel( 0, 0, 10, this, tr( "FX channel" ) ), // change this so it's a combo box, all the channels and then new. + m_effectChannelModel( 0, 0, 0, this, tr( "FX channel" ) ), // change this so it's a combo box, all the channels and then new. m_instrument( NULL ), m_soundShaping( this ), m_arpeggiator( this ), m_chordCreator( this ), m_piano( this ) { + m_effectChannelModel.setRange( 0, engine::fxMixer()->numChannels()-1, 1); connect( baseNoteModel(), SIGNAL( dataChanged() ), this, SLOT( updateBaseNote() ) ); connect( &m_pitchModel, SIGNAL( dataChanged() ),