diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2010-03-02 18:05:26 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2010-03-02 18:05:26 +0000 |
commit | 17088ee3ea5af1e6174b098bb5bcfdaec6ebf9b0 (patch) | |
tree | cbf9fe8fb94212f9a50c6b760ebaac3b4a1bcec6 /libs/ardour/midi_diskstream.cc | |
parent | a5ab2e99e19d5f5d4c1f91f38cd774fefdf257dc (diff) |
(1) remove most uses of MementoCommand for Playlist and Region (2) move frozen state from Region into Stateful, renamed "suspend property changes" (3) successive changes to a Property (scalar) after clear_history() do not keep resetting the old value (fixes region trim)
git-svn-id: svn://localhost/ardour2/branches/3.0@6720 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/midi_diskstream.cc')
-rw-r--r-- | libs/ardour/midi_diskstream.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/ardour/midi_diskstream.cc b/libs/ardour/midi_diskstream.cc index ccfaeaa5cd..836fb05c8b 100644 --- a/libs/ardour/midi_diskstream.cc +++ b/libs/ardour/midi_diskstream.cc @@ -35,6 +35,7 @@ #include "pbd/xml++.h" #include "pbd/memento_command.h" #include "pbd/enumwriter.h" +#include "pbd/stateful_diff_command.h" #include "ardour/ardour.h" #include "ardour/audioengine.h" @@ -1011,7 +1012,7 @@ MidiDiskstream::transport_stopped (struct tm& /*when*/, time_t /*twhen*/, bool a // cerr << _name << ": there are " << capture_info.size() << " capture_info records\n"; - XMLNode &before = _playlist->get_state(); + _playlist->clear_history (); _playlist->freeze (); uint32_t buffer_position = 0; @@ -1053,8 +1054,7 @@ MidiDiskstream::transport_stopped (struct tm& /*when*/, time_t /*twhen*/, bool a } _playlist->thaw (); - XMLNode &after = _playlist->get_state(); - _session.add_command (new MementoCommand<Playlist>(*_playlist, &before, &after)); + _session.add_command (new StatefulDiffCommand(_playlist)); } |