mirror of
https://github.com/LMMS/lmms.git
synced 2026-05-17 19:24:52 -04:00
DataFile: write new header information only for song projects
No need to write these for presets etc.
This commit is contained in:
@@ -689,16 +689,19 @@ void DataFile::upgrade()
|
||||
documentElement().setAttribute( "creator", "LMMS" );
|
||||
documentElement().setAttribute( "creatorversion", LMMS_VERSION );
|
||||
|
||||
// Time-signature
|
||||
if ( !m_head.hasAttribute( "timesig_numerator" ) )
|
||||
if( type() == SongProject || type() == SongProjectTemplate )
|
||||
{
|
||||
m_head.setAttribute( "timesig_numerator", 4 );
|
||||
m_head.setAttribute( "timesig_denominator", 4 );
|
||||
}
|
||||
// Time-signature
|
||||
if ( !m_head.hasAttribute( "timesig_numerator" ) )
|
||||
{
|
||||
m_head.setAttribute( "timesig_numerator", 4 );
|
||||
m_head.setAttribute( "timesig_denominator", 4 );
|
||||
}
|
||||
|
||||
if( !m_head.hasAttribute( "mastervol" ) )
|
||||
{
|
||||
m_head.setAttribute( "mastervol", 100 );
|
||||
if( !m_head.hasAttribute( "mastervol" ) )
|
||||
{
|
||||
m_head.setAttribute( "mastervol", 100 );
|
||||
}
|
||||
}
|
||||
//printf("%s\n", toString( 2 ).toUtf8().constData());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user