Don't add origin value to MIDI controller regions on initial insert.
This should probably hijack the same modifier as the guard points and work the same on all automation tracks, but I did it this way to not change behaviour of track automation where a default is much more reasonable.
This commit is contained in:
@@ -477,7 +477,7 @@ ControlList::editor_add (double when, double value)
|
||||
}
|
||||
|
||||
void
|
||||
ControlList::add (double when, double value, bool with_guards)
|
||||
ControlList::add (double when, double value, bool with_guards, bool with_default)
|
||||
{
|
||||
/* this is for making changes from some kind of user interface or
|
||||
control surface (GUI, MIDI, OSC etc)
|
||||
@@ -494,7 +494,7 @@ ControlList::add (double when, double value, bool with_guards)
|
||||
ControlEvent cp (when, 0.0f);
|
||||
iterator insertion_point;
|
||||
|
||||
if (_events.empty()) {
|
||||
if (_events.empty() && with_default) {
|
||||
|
||||
/* as long as the point we're adding is not at zero,
|
||||
* add an "anchor" point there.
|
||||
|
||||
Reference in New Issue
Block a user