diff --git a/webmusic.js b/webmusic.js index 24de390..03e57a3 100644 --- a/webmusic.js +++ b/webmusic.js @@ -142,6 +142,14 @@ function initState() { total = queue.length; } +function previousTrack() { + if (index-- === 0) + index = total-1; + if (continuelist) { + playSong(queue[index]) + } +} + function nextTrack() { if (++index === total) index = 0;