89 |
// keep the dimension regions and samples that are in use |
// keep the dimension regions and samples that are in use |
90 |
pInstrumentManager->HandBackInstrument(cmd.pInstrument, this, cmd.pRegionsInUse); |
pInstrumentManager->HandBackInstrument(cmd.pInstrument, this, cmd.pRegionsInUse); |
91 |
} |
} |
92 |
|
if (cmd.pScript) { |
93 |
|
// give old instrument script back to instrument resource manager |
94 |
|
cmd.pScript->resetAll(); |
95 |
|
} |
96 |
cmd.pRegionsInUse->clear(); |
cmd.pRegionsInUse->clear(); |
97 |
|
|
98 |
// delete all key groups |
// delete all key groups |
157 |
InstrumentIdxName = newInstrument->pInfo->Name; |
InstrumentIdxName = newInstrument->pInfo->Name; |
158 |
InstrumentStat = 100; |
InstrumentStat = 100; |
159 |
|
|
160 |
ChangeInstrument(newInstrument); |
cmd = ChangeInstrument(newInstrument); |
161 |
|
if (cmd.pScript) { |
162 |
|
// give old instrument script back to instrument resource manager |
163 |
|
cmd.pScript->resetAll(); |
164 |
|
} |
165 |
|
|
166 |
StatusChanged(true); |
StatusChanged(true); |
167 |
} |
} |