13
0

Fix loading of MIDI tracks.

git-svn-id: svn://localhost/ardour2/branches/3.0@6947 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2010-04-21 21:44:10 +00:00
parent 950ac6ef2b
commit b32efee4b3

View File

@ -80,7 +80,7 @@ MidiTrack::use_new_diskstream ()
ds->do_refill_with_alloc ();
ds->set_block_size (_session.get_block_size ());
set_diskstream (boost::dynamic_pointer_cast<MidiDiskstream> (ds));
set_diskstream (ds);
}
void
@ -150,6 +150,14 @@ MidiTrack::_set_state (const XMLNode& node, int version, bool call_base)
}
}
if (version >= 3000) {
if ((child = find_named_node (node, X_("Diskstream"))) != 0) {
boost::shared_ptr<MidiDiskstream> ds (new MidiDiskstream (_session, *child));
ds->do_refill_with_alloc ();
set_diskstream (ds);
}
}
pending_state = const_cast<XMLNode*> (&node);
if (_session.state_of_the_state() & Session::Loading) {