summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2010-06-10 22:56:46 +0000
committerCarl Hetherington <carl@carlh.net>2010-06-10 22:56:46 +0000
commitb23861609ef96f9e8dbf1559323497a2e8373d6e (patch)
tree3fc0ec6dc1719cf376ac10f8073b3799f3417d5c
parent07500f2250ff0af24224822012dbc45088ad1f2d (diff)
Preserve region state as well as playlist state in undo of bounce range. Fixes #3234.
git-svn-id: svn://localhost/ardour2/branches/3.0@7252 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r--gtk2_ardour/editor_ops.cc10
1 files changed, 9 insertions, 1 deletions
diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc
index 9b14bcdaaf..9206f1516b 100644
--- a/gtk2_ardour/editor_ops.cc
+++ b/gtk2_ardour/editor_ops.cc
@@ -3662,6 +3662,8 @@ Editor::bounce_range_selection (bool replace, bool enable_processing)
InterThreadInfo itt;
playlist->clear_history ();
+ playlist->clear_owned_history ();
+
boost::shared_ptr<Region> r = rtv->track()->bounce_range (start, start+cnt, itt, enable_processing);
if (replace) {
@@ -3671,7 +3673,13 @@ Editor::bounce_range_selection (bool replace, bool enable_processing)
playlist->add_region (r, start);
}
- _session->add_command (new StatefulDiffCommand (playlist));
+ vector<StatefulDiffCommand*> cmds;
+ playlist->rdiff (cmds);
+ for (vector<StatefulDiffCommand*>::iterator j = cmds.begin(); j != cmds.end(); ++j) {
+ _session->add_command (*j);
+ }
+
+ _session->add_command (new StatefulDiffCommand (playlist));
}
commit_reversible_command ();