diff options
author | Carl Hetherington <carl@carlh.net> | 2010-08-26 01:44:11 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2010-08-26 01:44:11 +0000 |
commit | c243a02c998f585295f2179657673e2cf0fa4428 (patch) | |
tree | 1a18ca901b5f7fb1270938e2fb62f7e2636400ef /gtk2_ardour/route_time_axis.cc | |
parent | df2fd9491904aba95e08e1e26552be609530ee83 (diff) |
Fix crossfade undo using the stateful diff system. Fixes #3257.
git-svn-id: svn://localhost/ardour2/branches/3.0@7694 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/route_time_axis.cc')
-rw-r--r-- | gtk2_ardour/route_time_axis.cc | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/gtk2_ardour/route_time_axis.cc b/gtk2_ardour/route_time_axis.cc index 391b08eac6..abc8101195 100644 --- a/gtk2_ardour/route_time_axis.cc +++ b/gtk2_ardour/route_time_axis.cc @@ -1339,13 +1339,10 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op) if ((what_we_got = playlist->cut (time)) != 0) { _editor.get_cut_buffer().add (what_we_got); - vector<StatefulDiffCommand*> cmds; - + vector<Command*> cmds; playlist->rdiff (cmds); - - for (vector<StatefulDiffCommand*>::iterator c = cmds.begin(); c != cmds.end(); ++c) { - _session->add_command (*c); - } + _session->add_commands (cmds); + _session->add_command (new StatefulDiffCommand (playlist)); } break; @@ -1357,13 +1354,10 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op) case Clear: if ((what_we_got = playlist->cut (time)) != 0) { - vector<StatefulDiffCommand*> cmds; - + + vector<Command*> cmds; playlist->rdiff (cmds); - - for (vector<StatefulDiffCommand*>::iterator c = cmds.begin(); c != cmds.end(); ++c) { - _session->add_command (*c); - } + _session->add_commands (cmds); _session->add_command (new StatefulDiffCommand (playlist)); what_we_got->release (); } |