using namespace std;
using namespace ARDOUR;
+PBD::Signal1<void,Marker*> Marker::CatchDeletion;
+
Marker::Marker (PublicEditor& ed, ArdourCanvas::Group& parent, guint32 rgba, const string& annotation,
Type type, nframes_t frame, bool handle_events)
set_name (annotation.c_str());
- editor.ZoomChanged.connect (mem_fun (*this, &Marker::reposition));
+ editor.ZoomChanged.connect (sigc::mem_fun (*this, &Marker::reposition));
mark->set_data ("marker", this);
if (handle_events) {
- group->signal_event().connect (bind (mem_fun (editor, &PublicEditor::canvas_marker_event), mark, this));
+ group->signal_event().connect (sigc::bind (sigc::mem_fun (editor, &PublicEditor::canvas_marker_event), mark, this));
}
line = 0;
Marker::~Marker ()
{
- drop_references ();
+ CatchDeletion (this); /* EMIT SIGNAL */
/* destroying the parent group destroys its contents, namely any polygons etc. that we added */
delete name_pixbuf;
line->property_x2() = unit_position + shift;
line->property_y2() = y_origin + initial_height;
- line->signal_event().connect (bind (mem_fun (editor, &PublicEditor::canvas_marker_event), mark, this));
+ line->signal_event().connect (sigc::bind (sigc::mem_fun (editor, &PublicEditor::canvas_marker_event), mark, this));
}
show_line ();
_tempo (temp)
{
set_position (_tempo.frame());
- group->signal_event().connect (bind (mem_fun (editor, &PublicEditor::canvas_tempo_marker_event), mark, this));
+ group->signal_event().connect (sigc::bind (sigc::mem_fun (editor, &PublicEditor::canvas_tempo_marker_event), mark, this));
}
TempoMarker::~TempoMarker ()
_meter (m)
{
set_position (_meter.frame());
- group->signal_event().connect (bind (mem_fun (editor, &PublicEditor::canvas_meter_marker_event), mark, this));
+ group->signal_event().connect (sigc::bind (sigc::mem_fun (editor, &PublicEditor::canvas_meter_marker_event), mark, this));
}
MeterMarker::~MeterMarker ()