Close #839, the Shift Times function will now only do something if shifting by a non-zero number of milliseconds, or always if shifting by a number of frames (even zero).

Originally committed to SVN as r3017.
This commit is contained in:
Niels Martin Hansen 2009-06-05 00:02:26 +00:00
parent ce015fc820
commit 2feefd85fd

View file

@ -221,6 +221,13 @@ void DialogShiftTimes::OnOK(wxCommandEvent &event) {
if (byTime) len = ShiftTime->time.GetMS(); if (byTime) len = ShiftTime->time.GetMS();
else ShiftFrame->GetValue().ToLong(&len); else ShiftFrame->GetValue().ToLong(&len);
if (byTime && len == 0) {
// Shift zero milliseconds in time mode
// Equivalent to doing nothing at all, so just dismiss
EndModal(0);
return;
}
// If backwards, invert // If backwards, invert
if (backward) len = -len; if (backward) len = -len;