AutomationLine::show ()
{
if (_visible & Line) {
- if (alist->interpolation() != AutomationList::Discrete) {
+ /* Only show the line there are some points, otherwise we may show an out-of-date line
+ when automation points have been removed (the line will still follow the shape of the
+ old points).
+ */
+ if (alist->interpolation() != AutomationList::Discrete && control_points.size() >= 2) {
line->show();
} else {
line->hide ();
}
_drag_had_movement = true;
- did_push = with_push;
+ if (with_push) {
+ did_push = with_push;
+ }
return clamped;
}
view_to_model_coord_y (view_y);
alist->modify (cp.model(), view_x, view_y);
-
- if (did_push) {
- /* move all points after cp by the same distance */
- alist->slide (cp.model()++, _time_converter->from (distance));
- }
}
bool