summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/midi_model.h
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-03-29 11:52:25 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-03-29 11:52:25 -0400
commit86f1b8c71f7cfae210d66bb97d3c513eade0c40e (patch)
treee3d0a2033a999614bdf99ad3e42e82a22d410edc /libs/ardour/ardour/midi_model.h
parentf1ce235b6bc10a336822a052cee517fa923def48 (diff)
major fixes for MIDI patch change and note undo/redo. Patch change handling was completely broken because of the use of absolute floating point comparisons for time comparison, and serialization/deserialization of patch change property changes was borked because of int/char conversions by stringstream. Note undo/redo would fail for note removal if a note had been moved and/or had its note number changed as the next operation after it was added, because time-based lookup would fail. Similar small changes made for sysex messages, which just needed the musical_time comparisons and nothing else
Diffstat (limited to 'libs/ardour/ardour/midi_model.h')
-rw-r--r--libs/ardour/ardour/midi_model.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/libs/ardour/ardour/midi_model.h b/libs/ardour/ardour/midi_model.h
index 0d11f940b9..3ecfca7d1c 100644
--- a/libs/ardour/ardour/midi_model.h
+++ b/libs/ardour/ardour/midi_model.h
@@ -114,6 +114,8 @@ public:
struct NoteChange {
NoteDiffCommand::Property property;
NotePtr note;
+ uint32_t note_id;
+
union {
uint8_t old_value;
TimeType old_time;
@@ -161,6 +163,7 @@ public:
private:
struct Change {
boost::shared_ptr<Evoral::Event<TimeType> > sysex;
+ gint sysex_id;
SysExDiffCommand::Property property;
TimeType old_time;
TimeType new_time;
@@ -204,6 +207,7 @@ public:
struct Change {
PatchChangePtr patch;
Property property;
+ gint patch_id;
union {
TimeType old_time;
uint8_t old_channel;