vcvxc
This commit is contained in:
parent
23a3af3c2e
commit
a5291b96d4
4 changed files with 15 additions and 5 deletions
|
@ -12,8 +12,16 @@ if (!playing)
|
|||
audio.loop=true;
|
||||
|
||||
function toggle() {
|
||||
if (audio.paused) audio.play()
|
||||
else audio.pause()
|
||||
if (audio.paused)
|
||||
{
|
||||
audio.play()
|
||||
localStorage.setItem("playing", "1")
|
||||
}
|
||||
else
|
||||
{
|
||||
audio.pause()
|
||||
localStorage.setItem("playing", "")
|
||||
}
|
||||
}
|
||||
|
||||
audio.play();
|
||||
|
@ -43,11 +51,13 @@ if (!playing)
|
|||
{
|
||||
audio.play()
|
||||
localStorage.setItem("paused", "")
|
||||
localStorage.setItem("playing", "1")
|
||||
}
|
||||
else
|
||||
{
|
||||
audio.pause()
|
||||
localStorage.setItem("paused", "1")
|
||||
localStorage.setItem("playing", "")
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue