| 1284 | } |
| 1285 | |
| 1286 | void VSTPlugin::LoadState(FileStreamIn& in, int rev) |
| 1287 | { |
| 1288 | if (rev >= 3) |
| 1289 | { |
| 1290 | LoadVSTFromSaveData(in, rev); |
| 1291 | } |
| 1292 | else |
| 1293 | { |
| 1294 | //make all sliders, like we used to, so that the controls can load correctly |
| 1295 | for (auto& parameter : mParameterSliders) |
| 1296 | { |
| 1297 | if (parameter.mSlider == nullptr) |
| 1298 | parameter.MakeSlider(); |
| 1299 | } |
| 1300 | } |
| 1301 | |
| 1302 | IDrawableModule::LoadState(in, rev); |
| 1303 | |
| 1304 | if (ModularSynth::sLoadingFileSaveStateRev < 423) |
| 1305 | in >> rev; |
| 1306 | LoadStateValidate(rev <= GetModuleSaveStateRev()); |
| 1307 | |
| 1308 | if (rev < 3) |
| 1309 | LoadVSTFromSaveData(in, rev); |
| 1310 | } |
| 1311 | |
| 1312 | void VSTPlugin::LoadVSTFromSaveData(FileStreamIn& in, int rev) |
| 1313 | { |
nothing calls this directly
no test coverage detected