Do not create automation when shifting (insert/remove time)

This fixes a bug when shift() creates automation for parameters that
can not have any automation (hidden parameters, Mixbus PRE).

The GUI (RTAV) aborts() when it finds an automation lane for
a hidden parameter.

This also cleans up shift() operations in general. Empty automation
lanes should be left alone, no guard-point at zero should be added.
This commit is contained in:
Robin Gareus 2019-03-25 17:05:19 +01:00
parent 3448f3151e
commit 60262275af
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -4224,6 +4224,9 @@ Route::shift (samplepos_t pos, samplecnt_t samples)
boost::shared_ptr<AutomationControl> ac = (*i)->automation_control (*p);
if (ac) {
boost::shared_ptr<AutomationList> al = ac->alist();
if (al->empty ()) {
continue;
}
XMLNode &before = al->get_state ();
al->shift (pos, samples);
XMLNode &after = al->get_state ();