diff options
author | nick_m <mainsbridge@gmail.com> | 2015-09-27 00:57:52 +1000 |
---|---|---|
committer | nick_m <mainsbridge@gmail.com> | 2015-10-20 00:53:28 +1100 |
commit | 9c102fa8d20b932f9a9879298764c0351a0e5acc (patch) | |
tree | ed9bbf05a2b6771d1dbe9e86b5e586f24c2debc1 /libs/ardour/automatable.cc | |
parent | 877b258c74aa6e2fa737ca9112900dca8bce6628 (diff) |
Make automation record undo per pass rather than per touch.
Diffstat (limited to 'libs/ardour/automatable.cc')
-rw-r--r-- | libs/ardour/automatable.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libs/ardour/automatable.cc b/libs/ardour/automatable.cc index 0b316890bc..1c72f202b2 100644 --- a/libs/ardour/automatable.cc +++ b/libs/ardour/automatable.cc @@ -365,7 +365,7 @@ Automatable::transport_located (framepos_t now) boost::shared_ptr<AutomationList> l = boost::dynamic_pointer_cast<AutomationList>(c->list()); - if (l) { + if (l && l->automation_state () == Write) { l->start_write_pass (now); } } @@ -394,7 +394,12 @@ Automatable::transport_stopped (framepos_t now) when the transport is re-started, a touch will magically be happening without it ever have being started in the usual way. */ + const bool list_did_write = !l->in_new_write_pass (); + l->stop_touch (true, now); + if (list_did_write) { + c->commit_transaction (); + } l->write_pass_finished (now, Config->get_automation_thinning_factor()); if (l->automation_playback()) { |