44 |
} |
} |
45 |
#endif |
#endif |
46 |
|
|
47 |
InstrumentForm::InstrumentForm(QWidget* parent) : QDialog(parent) { |
InstrumentForm::InstrumentForm ( QWidget* pParent ) |
48 |
|
: QDialog(pParent) |
49 |
|
{ |
50 |
ui.setupUi(this); |
ui.setupUi(this); |
51 |
|
|
52 |
// Initialize locals. |
// Initialize locals. |
98 |
SLOT(reject())); |
SLOT(reject())); |
99 |
} |
} |
100 |
|
|
101 |
InstrumentForm::~InstrumentForm() { |
|
102 |
|
InstrumentForm::~InstrumentForm (void) |
103 |
|
{ |
104 |
} |
} |
105 |
|
|
106 |
|
|
107 |
// Channel dialog setup formal initializer. |
// Channel dialog setup formal initializer. |
108 |
void InstrumentForm::setup ( qsamplerInstrument *pInstrument ) |
void InstrumentForm::setup ( qsamplerInstrument *pInstrument ) |
109 |
{ |
{ |
194 |
Qt::MatchExactly | Qt::MatchCaseSensitive) < 0) { |
Qt::MatchExactly | Qt::MatchCaseSensitive) < 0) { |
195 |
ui.EngineNameComboBox->addItem(sEngineName); |
ui.EngineNameComboBox->addItem(sEngineName); |
196 |
} |
} |
197 |
ui.EngineNameComboBox->setItemText( |
ui.EngineNameComboBox->setCurrentIndex( |
198 |
ui.EngineNameComboBox->currentIndex(), |
ui.EngineNameComboBox->findText(sEngineName, |
199 |
sEngineName); |
Qt::MatchExactly | Qt::MatchCaseSensitive)); |
200 |
|
|
201 |
// Instrument filename and index... |
// Instrument filename and index... |
202 |
QString sInstrumentFile = m_pInstrument->instrumentFile(); |
QString sInstrumentFile = m_pInstrument->instrumentFile(); |
203 |
if (sInstrumentFile.isEmpty()) |
if (sInstrumentFile.isEmpty()) |
204 |
sInstrumentFile = qsamplerChannel::noInstrumentName(); |
sInstrumentFile = qsamplerChannel::noInstrumentName(); |
205 |
ui.InstrumentFileComboBox->setItemText( |
ui.InstrumentFileComboBox->setEditText(sInstrumentFile); |
|
ui.InstrumentFileComboBox->currentIndex(), |
|
|
sInstrumentFile); |
|
206 |
ui.InstrumentNrComboBox->clear(); |
ui.InstrumentNrComboBox->clear(); |
207 |
ui.InstrumentNrComboBox->insertItems(0, |
ui.InstrumentNrComboBox->insertItems(0, |
208 |
qsamplerChannel::getInstrumentList(sInstrumentFile, |
qsamplerChannel::getInstrumentList(sInstrumentFile, |
262 |
if (sInstrumentFile.isEmpty()) |
if (sInstrumentFile.isEmpty()) |
263 |
return; |
return; |
264 |
|
|
265 |
ui.InstrumentFileComboBox->setItemText( |
ui.InstrumentFileComboBox->setEditText(sInstrumentFile); |
|
ui.InstrumentFileComboBox->currentIndex(), |
|
|
sInstrumentFile); |
|
|
|
|
266 |
updateInstrumentName(); |
updateInstrumentName(); |
267 |
} |
} |
268 |
|
|