Fix order of destruction for sequences.
This commit is contained in:
parent
3717eb12c3
commit
4c45197003
|
@ -83,6 +83,8 @@ public:
|
|||
|
||||
~Annotation_Sequence ( )
|
||||
{
|
||||
track()->remove( this );
|
||||
|
||||
log_destroy();
|
||||
}
|
||||
|
||||
|
|
|
@ -49,6 +49,8 @@ Audio_Sequence::Audio_Sequence ( Track *track ) : Sequence( track )
|
|||
|
||||
Audio_Sequence::~Audio_Sequence ( )
|
||||
{
|
||||
track()->remove( this );
|
||||
|
||||
log_destroy();
|
||||
}
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@ using namespace std;
|
|||
#include "Track.H"
|
||||
#include "Engine/Port.H"
|
||||
|
||||
#include "Engine/Engine.H" // for lock()
|
||||
#include "Transport.H" // for transport->frame
|
||||
|
||||
bool Control_Sequence::draw_with_gradient = true;
|
||||
|
@ -50,9 +51,19 @@ Control_Sequence::~Control_Sequence ( )
|
|||
{
|
||||
log_destroy();
|
||||
|
||||
engine->lock();
|
||||
|
||||
track()->remove( this );
|
||||
|
||||
engine->unlock();
|
||||
|
||||
_output->shutdown();
|
||||
|
||||
delete _output;
|
||||
|
||||
_output = NULL;
|
||||
|
||||
log_destroy();
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -75,10 +75,6 @@ Sequence::~Sequence ( )
|
|||
}
|
||||
|
||||
_widgets.clear();
|
||||
|
||||
parent()->redraw();
|
||||
parent()->remove( this );
|
||||
// log_destroy();
|
||||
}
|
||||
|
||||
nframes_t
|
||||
|
|
|
@ -354,13 +354,25 @@ Track::add ( Audio_Sequence * t )
|
|||
void
|
||||
Track::remove ( Audio_Sequence *t )
|
||||
{
|
||||
timeline->wrlock();
|
||||
|
||||
takes->remove( t );
|
||||
|
||||
timeline->unlock();
|
||||
|
||||
resize();
|
||||
|
||||
// take_menu->remove( t->name() );
|
||||
}
|
||||
|
||||
void
|
||||
Track::remove ( Annotation_Sequence *t )
|
||||
{
|
||||
annotation->remove( t );
|
||||
|
||||
resize();
|
||||
}
|
||||
|
||||
void
|
||||
Track::remove ( Control_Sequence *t )
|
||||
{
|
||||
|
@ -371,8 +383,6 @@ Track::remove ( Control_Sequence *t )
|
|||
engine->unlock();
|
||||
|
||||
resize();
|
||||
|
||||
redraw();
|
||||
}
|
||||
|
||||
void
|
||||
|
|
Loading…
Reference in New Issue