revert recent change to Evoral::Event, and use static_cast<> to get from Event to MIDIEvent

git-svn-id: svn://localhost/ardour2/branches/3.0@10870 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Paul Davis 2011-12-02 20:34:58 +00:00
parent 07b4626ea5
commit 14d601a0ff
3 changed files with 5 additions and 5 deletions

View File

@ -1240,7 +1240,7 @@ MidiRegionView::display_sysexes()
for (MidiModel::SysExes::const_iterator i = _model->sysexes().begin(); i != _model->sysexes().end(); ++i) {
const boost::shared_ptr<const Evoral::MIDIEvent<Evoral::MusicalTime> > mev =
boost::dynamic_pointer_cast<const Evoral::MIDIEvent<Evoral::MusicalTime> > (*i);
boost::static_pointer_cast<const Evoral::MIDIEvent<Evoral::MusicalTime> > (*i);
if (mev) {
if (mev->is_spp() || mev->is_mtc_quarter() || mev->is_mtc_full()) {
@ -1273,7 +1273,7 @@ MidiRegionView::display_sysexes()
for (MidiModel::SysExes::const_iterator i = _model->sysexes().begin(); i != _model->sysexes().end(); ++i) {
const boost::shared_ptr<const Evoral::MIDIEvent<Evoral::MusicalTime> > mev =
boost::dynamic_pointer_cast<const Evoral::MIDIEvent<Evoral::MusicalTime> > (*i);
boost::static_pointer_cast<const Evoral::MIDIEvent<Evoral::MusicalTime> > (*i);
Evoral::MusicalTime time = (*i)->time();
assert (time >= 0);

View File

@ -56,7 +56,7 @@ struct Event {
*/
Event(const Event& copy, bool alloc);
virtual ~Event();
~Event();
const Event& operator=(const Event& copy);

View File

@ -31,8 +31,8 @@ namespace Evoral {
/** MIDI helper functions for an Event.
*
* This class contains no data, an event can be cast to a MIDIEvent
* but the application must make sure the event actually contains
* This class contains no data, an Evoral::Event can be cast to a MIDIEvent
* but the application must make sure the Event actually contains
* valid MIDI data for these functions to make sense.
*/
template<typename Time>