mirror of
https://codeberg.org/ashley/poke.git
synced 2024-11-22 17:57:52 +01:00
add new loop gui :3
This commit is contained in:
parent
be731b79f0
commit
50d3f3ffc0
1 changed files with 17 additions and 7 deletions
24
css/app.js
24
css/app.js
|
@ -298,14 +298,24 @@ function fetchUrls(urls) {
|
||||||
popupMenu.style.display = "none";
|
popupMenu.style.display = "none";
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
var loopedIndicator = document.getElementById("loopedIndicator");
|
||||||
|
|
||||||
|
loopedIndicator.style.display = "none"; // Initially hide the indicator
|
||||||
|
|
||||||
loopOption.addEventListener("click", function() {
|
loopOption.addEventListener("click", function() {
|
||||||
video.loop = !video.loop;
|
var looped = video.loop;
|
||||||
if (video.loop) {
|
video.loop = !looped;
|
||||||
alert("Looped!");
|
|
||||||
} else {
|
// Update the looped indicator popup
|
||||||
alert("unlooped!")
|
loopedIndicator.textContent = looped ? "Unlooped!" : "Looped!";
|
||||||
}
|
loopedIndicator.style.display = "block";
|
||||||
|
|
||||||
|
// Hide the indicator after 2 seconds
|
||||||
|
setTimeout(function() {
|
||||||
|
loopedIndicator.style.display = "none";
|
||||||
|
}, 2000);
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
speedOption.addEventListener("click", function() {
|
speedOption.addEventListener("click", function() {
|
||||||
|
|
Loading…
Reference in a new issue