view->session()->begin_reversible_command (_("add automation event"));
XMLNode& before = _line->the_list()->get_state();
- _line->the_list()->add (when_d, y, with_guard_points);
+ _line->the_list()->add (when_d, y, with_guard_points, false);
XMLNode& after = _line->the_list()->get_state();
virtual bool clamp_value (double& /*when*/, double& /*value*/) const { return true; }
- virtual void add (double when, double value, bool with_guards=true);
+ virtual void add (double when, double value, bool with_guards=true, bool with_default=true);
virtual void editor_add (double when, double value);
void fast_simple_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)
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.