1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-02 08:03:48 +02:00

Bug1735 addendum: fix oddities pasting left of Note track offset...

... See comment http://bugzilla.audacityteam.org/show_bug.cgi?id=1735#c3
This commit is contained in:
Paul Licameli 2017-09-08 11:29:21 -04:00
parent 761bd6bf83
commit cee28ab535

View File

@ -565,6 +565,14 @@ void NoteTrack::Paste(double t, const Track *src)
// THROW_INCONSISTENCY_EXCEPTION; // ?
return;
auto myOffset = this->GetOffset();
if (t < myOffset) {
// workaround strange behavior described at
// http://bugzilla.audacityteam.org/show_bug.cgi?id=1735#c3
SetOffset(t);
InsertSilence(t, myOffset - t);
}
NoteTrack* other = (NoteTrack*)src;
double delta = 0.0;