1
0
mirror of https://github.com/SuperBFG7/ympd synced 2024-12-23 01:20:27 +00:00

seek not allowed without song in queue

This commit is contained in:
Andrew Karpow 2014-01-17 16:41:54 +01:00
parent fc1d7c1242
commit da52814926

View File

@ -55,7 +55,7 @@ $(document).ready(function(){
});
$('#progressbar').slider(0);
$("#progressbar").on('slider.newValue', function(evt,data){
if(current_song) {
if(current_song && current_song.currentSongId >= 0) {
var seekVal = Math.ceil(current_song.totalTime*(data.val/100));
socket.send("MPD_API_SET_SEEK,"+current_song.currentSongId+","+seekVal);
}