mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 19:16:40 +01:00
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
This commit is contained in:
parent
df2fd94919
commit
c243a02c99
21 changed files with 225 additions and 72 deletions
|
|
@ -1037,6 +1037,15 @@ RegionMoveDrag::finished_no_copy (
|
|||
playlist->freeze ();
|
||||
}
|
||||
|
||||
/* this movement may result in a crossfade being modified, so we need to get undo
|
||||
data from the playlist as well as the region.
|
||||
*/
|
||||
|
||||
r = modified_playlists.insert (playlist);
|
||||
if (r.second) {
|
||||
playlist->clear_changes ();
|
||||
}
|
||||
|
||||
rv->region()->set_position (where, (void*) this);
|
||||
|
||||
_editor->session()->add_command (new StatefulDiffCommand (rv->region()));
|
||||
|
|
@ -1172,7 +1181,12 @@ void
|
|||
RegionMoveDrag::add_stateful_diff_commands_for_playlists (PlaylistSet const & playlists)
|
||||
{
|
||||
for (PlaylistSet::const_iterator i = playlists.begin(); i != playlists.end(); ++i) {
|
||||
_editor->session()->add_command (new StatefulDiffCommand (*i));
|
||||
StatefulDiffCommand* c = new StatefulDiffCommand (*i);
|
||||
if (!c->empty()) {
|
||||
_editor->session()->add_command (new StatefulDiffCommand (*i));
|
||||
} else {
|
||||
delete c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue