Save automation of * Track::muted * Track::solo * EffectChain::enabled
This commit is contained in:
committed by
Oskar Wallgren
parent
1ab1280843
commit
5c362e51ac
@@ -53,7 +53,7 @@ EffectChain::~EffectChain()
|
||||
|
||||
void EffectChain::saveSettings( QDomDocument & _doc, QDomElement & _this )
|
||||
{
|
||||
_this.setAttribute( "enabled", m_enabledModel.value() );
|
||||
m_enabledModel.saveSettings( _doc, _this, "enabled" );
|
||||
_this.setAttribute( "numofeffects", m_effects.count() );
|
||||
|
||||
for( Effect* effect : m_effects)
|
||||
@@ -80,7 +80,7 @@ void EffectChain::loadSettings( const QDomElement & _this )
|
||||
|
||||
// TODO This method should probably also lock the mixer
|
||||
|
||||
m_enabledModel.setValue( _this.attribute( "enabled" ).toInt() );
|
||||
m_enabledModel.loadSettings( _this, "enabled" );
|
||||
|
||||
const int plugin_cnt = _this.attribute( "numofeffects" ).toInt();
|
||||
|
||||
|
||||
@@ -2063,8 +2063,9 @@ void Track::saveSettings( QDomDocument & doc, QDomElement & element )
|
||||
}
|
||||
element.setAttribute( "type", type() );
|
||||
element.setAttribute( "name", name() );
|
||||
element.setAttribute( "muted", isMuted() );
|
||||
element.setAttribute( "solo", isSolo() );
|
||||
m_mutedModel.saveSettings( doc, element, "muted" );
|
||||
m_soloModel.saveSettings( doc, element, "solo" );
|
||||
|
||||
if( m_height >= MINIMAL_TRACK_HEIGHT )
|
||||
{
|
||||
element.setAttribute( "height", m_height );
|
||||
@@ -2116,8 +2117,8 @@ void Track::loadSettings( const QDomElement & element )
|
||||
setName( element.hasAttribute( "name" ) ? element.attribute( "name" ) :
|
||||
element.firstChild().toElement().attribute( "name" ) );
|
||||
|
||||
setMuted( element.attribute( "muted" ).toInt() );
|
||||
setSolo( element.attribute( "solo" ).toInt() );
|
||||
m_mutedModel.loadSettings( element, "muted" );
|
||||
m_soloModel.loadSettings( element, "solo" );
|
||||
|
||||
if( m_simpleSerializingMode )
|
||||
{
|
||||
@@ -2150,8 +2151,9 @@ void Track::loadSettings( const QDomElement & element )
|
||||
{
|
||||
loadTrackSpecificSettings( node.toElement() );
|
||||
}
|
||||
else if(
|
||||
!node.toElement().attribute( "metadata" ).toInt() )
|
||||
else if( node.nodeName() != "muted"
|
||||
&& node.nodeName() != "solo"
|
||||
&& !node.toElement().attribute( "metadata" ).toInt() )
|
||||
{
|
||||
TrackContentObject * tco = createTCO(
|
||||
MidiTime( 0 ) );
|
||||
|
||||
Reference in New Issue
Block a user