diff options
author | Hans Baier <hansfbaier@googlemail.com> | 2012-10-11 03:22:17 +0000 |
---|---|---|
committer | Hans Baier <hansfbaier@googlemail.com> | 2012-10-11 03:22:17 +0000 |
commit | 97c23848d7d4126dc948caac47476317d6752e4d (patch) | |
tree | 1c5eaa7d4d1041bab6bf9b97d9b4ee552c5e12d8 /libs/evoral/evoral/Sequence.hpp | |
parent | 9707a0e8271a54dd21e49d6ca9ae98378ac4f8a5 (diff) |
implement deleting of sysex events
git-svn-id: svn://localhost/ardour2/branches/3.0@13238 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/evoral/evoral/Sequence.hpp')
-rw-r--r-- | libs/evoral/evoral/Sequence.hpp | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/libs/evoral/evoral/Sequence.hpp b/libs/evoral/evoral/Sequence.hpp index cb851cf2f6..815d02f980 100644 --- a/libs/evoral/evoral/Sequence.hpp +++ b/libs/evoral/evoral/Sequence.hpp @@ -181,7 +181,16 @@ public: void set_notes (const Sequence<Time>::Notes& n); - typedef std::vector< boost::shared_ptr< Event<Time> > > SysExes; + typedef boost::shared_ptr< Event<Time> > SysExPtr; + typedef boost::shared_ptr<const Event<Time> > constSysExPtr; + + struct EarlierSysExComparator { + inline bool operator() (constSysExPtr a, constSysExPtr b) const { + return a->time() < b->time(); + } + }; + + typedef std::multiset<SysExPtr, EarlierSysExComparator> SysExes; inline SysExes& sysexes() { return _sysexes; } inline const SysExes& sysexes() const { return _sysexes; } @@ -262,6 +271,7 @@ public: typename Notes::const_iterator note_lower_bound (Time t) const; typename PatchChanges::const_iterator patch_change_lower_bound (Time t) const; + typename SysExes::const_iterator sysex_lower_bound (Time t) const; bool control_to_midi_event(boost::shared_ptr< Event<Time> >& ev, const ControlIterator& iter) const; @@ -279,6 +289,9 @@ public: void add_patch_change_unlocked (const PatchChangePtr); void remove_patch_change_unlocked (const constPatchChangePtr); + void add_sysex_unlocked (const SysExPtr); + void remove_sysex_unlocked (const SysExPtr); + uint8_t lowest_note() const { return _lowest_note; } uint8_t highest_note() const { return _highest_note; } |