mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-28 09:27:39 +01:00
Ripple mode: ripple when deleting ranges.
Make delete, cut and clear of a range ripple the appropriate playlists.
This commit is contained in:
parent
c9157e00d3
commit
9ae10442c3
1 changed files with 11 additions and 0 deletions
|
|
@ -1019,6 +1019,10 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op)
|
|||
switch (op) {
|
||||
case Delete:
|
||||
if (playlist->cut (time) != 0) {
|
||||
if (Config->get_edit_mode() == Ripple)
|
||||
playlist->ripple(time.start() + time.length(), -time.length(), NULL);
|
||||
// no need to exclude any regions from rippling here
|
||||
|
||||
vector<Command*> cmds;
|
||||
playlist->rdiff (cmds);
|
||||
_session->add_commands (cmds);
|
||||
|
|
@ -1030,6 +1034,10 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op)
|
|||
case Cut:
|
||||
if ((what_we_got = playlist->cut (time)) != 0) {
|
||||
_editor.get_cut_buffer().add (what_we_got);
|
||||
if (Config->get_edit_mode() == Ripple)
|
||||
playlist->ripple(time.start() + time.length(), -time.length(), NULL);
|
||||
// no need to exclude any regions from rippling here
|
||||
|
||||
vector<Command*> cmds;
|
||||
playlist->rdiff (cmds);
|
||||
_session->add_commands (cmds);
|
||||
|
|
@ -1045,6 +1053,9 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op)
|
|||
|
||||
case Clear:
|
||||
if ((what_we_got = playlist->cut (time)) != 0) {
|
||||
if (Config->get_edit_mode() == Ripple)
|
||||
playlist->ripple(time.start() + time.length(), -time.length(), NULL);
|
||||
// no need to exclude any regions from rippling here
|
||||
|
||||
vector<Command*> cmds;
|
||||
playlist->rdiff (cmds);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue