diff options
author | Colin Fletcher <colin.m.fletcher@googlemail.com> | 2014-07-01 18:27:22 +0100 |
---|---|---|
committer | Colin Fletcher <colin.m.fletcher@googlemail.com> | 2014-07-01 18:38:14 +0100 |
commit | cabd3783fec773f40740e4427c32808b40012d9b (patch) | |
tree | 1965805a4698e94fc6352bac11fe3d59234ac4c9 | |
parent | 83ae6beca5371f5d277a76214807513ac681eac6 (diff) |
Ripple mode: fix undo of paste
Fix undo of region paste operations in ripple mode.
-rw-r--r-- | gtk2_ardour/route_time_axis.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gtk2_ardour/route_time_axis.cc b/gtk2_ardour/route_time_axis.cc index ed46278aa6..ff898b7895 100644 --- a/gtk2_ardour/route_time_axis.cc +++ b/gtk2_ardour/route_time_axis.cc @@ -1434,13 +1434,18 @@ RouteTimeAxisView::paste (framepos_t pos, float times, Selection& selection, siz DEBUG_TRACE (DEBUG::CutNPaste, string_compose ("modified paste to %1\n", pos)); } - pl->clear_changes (); + pl->clear_changes (); if (Config->get_edit_mode() == Ripple) { std::pair<framepos_t, framepos_t> extent = (*p)->get_extent(); framecnt_t amount = extent.second - extent.first; pl->ripple(pos, amount * times, boost::shared_ptr<Region>()); } pl->paste (*p, pos, times); + + vector<Command*> cmds; + pl->rdiff (cmds); + _session->add_commands (cmds); + _session->add_command (new StatefulDiffCommand (pl)); return true; |