Playback
Playlist | Last modified |
---|
# | Title | Artist | Album | Duration |
---|
Title | Artist | Album | Duration |
---|
Search
Title | Artist | Album | Duration |
---|
diff --git a/dist/htdocs/index.html b/dist/htdocs/index.html index c6cc019..7895072 100644 --- a/dist/htdocs/index.html +++ b/dist/htdocs/index.html @@ -1 +1 @@ -
"+a+'
Reload';b.classList.remove("hide");document.getElementById("appReloadBtn").addEventListener("click",function(){location.reload()},!1)} +function appInitStart(){appInited=!1;document.getElementsByTagName("header")[0].classList.add("hide");document.getElementsByTagName("main")[0].classList.add("hide");document.getElementsByTagName("footer")[0].classList.add("hide");initState("appInitSettings","load");initState("appInitWebsocket","blank");initState("appInitApply","blank");var a=document.getElementById("modalAppInitAlert");a.classList.add("hide");a.innerText="";modalAppInit.show();getSettings(!0);appInitWait()} +function appInitWait(){setTimeout(function(){if("true"==settingsParsed&&1==websocketConnected)initState("appInitWebsocket","ok"),initState("appInitApply","load"),appInit(),initState("appInitApply","ok"),document.getElementsByTagName("header")[0].classList.remove("hide"),document.getElementsByTagName("main")[0].classList.remove("hide"),document.getElementsByTagName("footer")[0].classList.remove("hide"),modalAppInit.hide(),appInited=!0;else{if("true"==settingsParsed)initState("appInitSettings","ok"), +initState("appInitWebsocket","load"),webSocketConnect();else if("error"==settingsParsed){initState("appInitSettings","error");return}appInitWait()}},500)} function appInit(){document.getElementById("btnChVolumeDown").addEventListener("click",function(a){a.stopPropagation()},!1);document.getElementById("btnChVolumeUp").addEventListener("click",function(a){a.stopPropagation()},!1);domCache.volumeBar.addEventListener("click",function(a){a.stopPropagation()},!1);domCache.volumeBar.addEventListener("change",function(a){sendAPI({cmd:"MPD_API_PLAYER_VOLUME_SET",data:{volume:domCache.volumeBar.value}})},!1);domCache.progressBar.value=0;domCache.progressBar.addEventListener("change", function(a){currentSong&&0<=currentSong.currentSongId&&sendAPI({cmd:"MPD_API_PLAYER_SEEK",data:{songid:currentSong.currentSongId,seek:Math.ceil(domCache.progressBar.value/1E3*currentSong.totalTime)}})},!1);document.getElementById("navDBupdate").addEventListener("click",function(a){a.stopPropagation();a.preventDefault();a=this.getElementsByTagName("span")[0];a.innerText="keyboard_arrow_right"==a.innerText?"keyboard_arrow_down":"keyboard_arrow_right"},!1);document.getElementById("volumeMenu").parentNode.addEventListener("show.bs.dropdown", function(){sendAPI({cmd:"MPD_API_PLAYER_OUTPUT_LIST"},parseOutputs)});document.getElementById("modalAbout").addEventListener("shown.bs.modal",function(){sendAPI({cmd:"MPD_API_DATABASE_STATS"},parseStats)});document.getElementById("modalAddToPlaylist").addEventListener("shown.bs.modal",function(){document.getElementById("addStreamFrm").classList.contains("hide")?document.getElementById("addToPlaylistPlaylist").focus():document.getElementById("streamUrl").focus()});document.getElementById("modalHelp").addEventListener("show.bs.modal", @@ -76,7 +78,8 @@ c.target);c=b.getElementsByClassName("dragover-th");for(var d=c.length,e=0;e