Commit 8091060d authored by luyikei's avatar luyikei

Workflow: Don't save all tracks including ones that have no clips

parent 70814fb7
...@@ -361,9 +361,14 @@ MainWorkflow::canRender() ...@@ -361,9 +361,14 @@ MainWorkflow::canRender()
void void
MainWorkflow::preSave() MainWorkflow::preSave()
{ {
int maxTrackId = 0;
for ( auto it = m_clips.cbegin(); it != m_clips.cend(); ++it )
maxTrackId = qMax( it.key(), maxTrackId );
QVariantList l; QVariantList l;
for ( auto track : m_tracks ) for ( int i = 0; i < maxTrackId + 1; ++i )
l << track->toVariant(); l << m_tracks[i]->toVariant();
m_settings->value( "tracks" )->set( l ); m_settings->value( "tracks" )->set( l );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment