X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fmidi_diskstream.cc;h=18d3bc5ce30681fe5d7df762a970b7247f3d2601;hb=535d60237486e2227d22e5febbcfbf868abb11e3;hp=f61211def8bf94efdd282d4d114e9f3ea600d4d4;hpb=de5e463904de7b58218a5bb1e9080ba5353bb985;p=ardour.git diff --git a/libs/ardour/midi_diskstream.cc b/libs/ardour/midi_diskstream.cc index f61211def8..18d3bc5ce3 100644 --- a/libs/ardour/midi_diskstream.cc +++ b/libs/ardour/midi_diskstream.cc @@ -53,6 +53,7 @@ #include "ardour/session.h" #include "ardour/smf_source.h" #include "ardour/utils.h" +#include "ardour/session_playlists.h" #include "midi++/types.h" @@ -220,7 +221,7 @@ MidiDiskstream::find_and_use_playlist (const string& name) { boost::shared_ptr playlist; - if ((playlist = boost::dynamic_pointer_cast (_session.playlist_by_name (name))) == 0) { + if ((playlist = boost::dynamic_pointer_cast (_session.playlists->by_name (name))) == 0) { playlist = boost::dynamic_pointer_cast (PlaylistFactory::create (DataType::MIDI, _session, name)); } @@ -1023,7 +1024,7 @@ MidiDiskstream::transport_stopped (struct tm& /*when*/, time_t /*twhen*/, bool a continue; /* XXX is this OK? */ } - region->GoingAway.connect (bind (mem_fun (*this, &Diskstream::remove_region_from_last_capture), boost::weak_ptr(region))); + region->DropReferences.connect_same_thread (*this, boost::bind (&Diskstream::remove_region_from_last_capture, this, boost::weak_ptr(region))); _last_capture_regions.push_back (region); @@ -1128,15 +1129,6 @@ MidiDiskstream::set_record_enabled (bool yn) assert(!destructive()); - if (yn && _source_port == 0) { - - /* pick up connections not initiated *from* the IO object - we're associated with. - */ - - get_input_sources (); - } - /* yes, i know that this not proof against race conditions, but its good enough. i think. */ @@ -1223,7 +1215,7 @@ MidiDiskstream::get_state () if (_session.config.get_punch_in() && ((pi = _session.locations()->auto_punch_location()) != 0)) { snprintf (buf, sizeof (buf), "%" PRId64, pi->start()); } else { - snprintf (buf, sizeof (buf), "%" PRIu32, _session.transport_frame()); + snprintf (buf, sizeof (buf), "%" PRId64, _session.transport_frame()); } cs_child->add_property (X_("at"), buf);