Don't let sample offest of length go negative (crashes RageAudio and doesn't make sense anyway)

This commit is contained in:
Glenn Maynard
2002-08-21 20:41:01 +00:00
parent b288aba0de
commit bc314e42c4
+2
View File
@@ -934,6 +934,7 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ
}
m_pSong->m_fMusicSampleStartSeconds += fOffsetDelta;
m_pSong->m_fMusicSampleStartSeconds = max(m_pSong->m_fMusicSampleStartSeconds,0);
}
break;
case DIK_SUBTRACT:
@@ -953,6 +954,7 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ
}
m_pSong->m_fMusicSampleLengthSeconds += fDelta;
m_pSong->m_fMusicSampleLengthSeconds = max(m_pSong->m_fMusicSampleLengthSeconds,0);
}
break;
}