Don't assume files only move forward in time (fixes #26)

This commit is contained in:
Marks Polakovs 2020-03-28 08:41:32 +01:00
parent f39a9d2232
commit 0e40f26438

View file

@ -359,9 +359,10 @@ export const load = (
});
wavesurfer.on("audioprocess", () => {
if (
wavesurfer.getCurrentTime() -
getState().mixer.players[player].timeCurrent >
0.5
Math.abs(
wavesurfer.getCurrentTime() -
getState().mixer.players[player].timeCurrent
) > 0.5
) {
dispatch(
mixerState.actions.setTimeCurrent({