Fix incorrect display of automation lines after points are

removed.


git-svn-id: svn://localhost/ardour2/branches/3.0@12645 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2012-06-10 14:14:01 +00:00
parent 0f039ad5a9
commit 92bf2dc1c2

View File

@ -136,7 +136,11 @@ void
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 ();