summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gtk2_ardour/automation_region_view.cc2
-rw-r--r--libs/evoral/evoral/ControlList.hpp2
-rw-r--r--libs/evoral/src/ControlList.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/gtk2_ardour/automation_region_view.cc b/gtk2_ardour/automation_region_view.cc
index 2726cf0455..59bc1f6250 100644
--- a/gtk2_ardour/automation_region_view.cc
+++ b/gtk2_ardour/automation_region_view.cc
@@ -176,7 +176,7 @@ AutomationRegionView::add_automation_event (GdkEvent *, framepos_t when, double
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();
diff --git a/libs/evoral/evoral/ControlList.hpp b/libs/evoral/evoral/ControlList.hpp
index daa4aa93a6..3c4b192159 100644
--- a/libs/evoral/evoral/ControlList.hpp
+++ b/libs/evoral/evoral/ControlList.hpp
@@ -121,7 +121,7 @@ public:
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);
diff --git a/libs/evoral/src/ControlList.cpp b/libs/evoral/src/ControlList.cpp
index 6717261713..bc8626c535 100644
--- a/libs/evoral/src/ControlList.cpp
+++ b/libs/evoral/src/ControlList.cpp
@@ -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.