Commit 26db1a17 authored by Hugo Beauzee-Luyssen's avatar Hugo Beauzee-Luyssen
Browse files

Solved a bug when dropping a video on a deactivated track.

parent 1d1267be
......@@ -76,13 +76,17 @@ void MainWorkflow::addClip( Clip* clip, unsigned int trackId, qint64 start )
Q_ASSERT_X( trackId < m_trackCount, "MainWorkflow::addClip",
"The specified trackId isn't valid, for it's higher than the number of tracks");
//if the track is deactivated, we need to reactivate it :
m_tracks[trackId]->addClip( clip, start );
//if the track is deactivated, we need to reactivate it.
if ( m_tracks[trackId].deactivated() == true )
activateTrack( trackId );
m_tracks[trackId]->addClip( clip, start );
//Now check if this clip addition has changed something about the workflow's length
if ( m_tracks[trackId]->getLength() > m_length )
m_length = m_tracks[trackId]->getLength();
//Inform the GUI
emit clipAdded( clip, trackId, start );
Supports Markdown
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