mirror of
https://github.com/SuperBFG7/ympd
synced 2025-05-16 14:14:11 +00:00
Fixed prev and next buttons
This commit is contained in:
parent
bd00810072
commit
ef7b7b9017
@ -38,7 +38,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btn-toolbar col-auto" role="toolbar">
|
<div class="btn-toolbar col-auto" role="toolbar">
|
||||||
<div class="btn-group mr-2" role="group">
|
<div class="btn-group mr-2" role="group">
|
||||||
<button id="btnPrev" type="button" class="btn btn-secondary" onclick="socket.send('MPD_API_SET_PREV');">
|
<button id="btnPrev" type="button" class="btn btn-secondary" onclick="clickPrev();;">
|
||||||
<span class="material-icons">skip_previous</span>
|
<span class="material-icons">skip_previous</span>
|
||||||
</button>
|
</button>
|
||||||
<button id="btnStop" type="button" class="btn btn-secondary" onclick="clickStop();">
|
<button id="btnStop" type="button" class="btn btn-secondary" onclick="clickStop();">
|
||||||
@ -47,7 +47,7 @@
|
|||||||
<button id="btnPlay" type="button" class="btn btn-secondary" onclick="clickPlay();">
|
<button id="btnPlay" type="button" class="btn btn-secondary" onclick="clickPlay();">
|
||||||
<span class="material-icons">pause</span>
|
<span class="material-icons">pause</span>
|
||||||
</button>
|
</button>
|
||||||
<button id="btnNext" type="button" class="btn btn-secondary" onclick="socket.send('MPD_API_SET_NEXT');">
|
<button id="btnNext" type="button" class="btn btn-secondary" onclick="clickNext();">
|
||||||
<span class="material-icons">skip_next</span>
|
<span class="material-icons">skip_next</span>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
@ -988,6 +988,14 @@ function clickStop() {
|
|||||||
sendAPI(JSON.stringify({"cmd":"MPD_API_SET_STOP"}));
|
sendAPI(JSON.stringify({"cmd":"MPD_API_SET_STOP"}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function clickPrev() {
|
||||||
|
sendAPI(JSON.stringify({"cmd":"MPD_API_SET_PREV"}));
|
||||||
|
}
|
||||||
|
|
||||||
|
function clickNext() {
|
||||||
|
sendAPI(JSON.stringify({"cmd":"MPD_API_SET_NEXT"}));
|
||||||
|
}
|
||||||
|
|
||||||
function setLocalStream(mpdhost,streamport) {
|
function setLocalStream(mpdhost,streamport) {
|
||||||
var mpdstream = 'http://';
|
var mpdstream = 'http://';
|
||||||
if ( mpdhost == '127.0.0.1' || mpdhost == 'localhost')
|
if ( mpdhost == '127.0.0.1' || mpdhost == 'localhost')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user