Skip to content
Permalink
Browse files
Set VST program first when restoring settings
Fixes a bug where some VSTs (e.g. Temper) would have their settings reset on project load, due to using programs as presets.
  • Loading branch information
DomClark authored and PhysSong committed Sep 11, 2018
1 parent 4c7c68f commit c3db486
Showing 1 changed file with 5 additions and 5 deletions.
@@ -157,6 +157,11 @@ void VstPlugin::tryLoad( const QString &remoteVstPluginExecutable )

void VstPlugin::loadSettings( const QDomElement & _this )
{
if( _this.hasAttribute( "program" ) )
{
setProgram( _this.attribute( "program" ).toInt() );
}

const int num_params = _this.attribute( "numparams" ).toInt();
// if it exists try to load settings chunk
if( _this.hasAttribute( "chunk" ) )
@@ -176,11 +181,6 @@ void VstPlugin::loadSettings( const QDomElement & _this )
}
setParameterDump( dump );
}

if( _this.hasAttribute( "program" ) )
{
setProgram( _this.attribute( "program" ).toInt() );
}
}


0 comments on commit c3db486

Please sign in to comment.