Comments (2)
Yeah.. the player is just meant to be a simple browser. Not even Next or Prev buttons, let alone Auto Next. Maybe I will fix that at some point, but no promises.
For now, a quick patch with minimal code would be adding this second if
condition to this progress bar update routine: https://github.com/bryc/ahx-web-player/blob/master/index.html#L244
if(WebAHX.Master.Output.Player.SongEndReached)
{
var list = document.querySelectorAll("z");
for(var i = 0; i < list.length; i++)
{
if(list[i].className === "selected")
{
list[i + 1].click();
break;
}
}
}
It's not perfect, but it works... mostly. But though there's a problem now. Some songs navigate and loop freely without ever setting SongEndReached
to 1. So I don't see a clean way to detect all cases. Maybe need to detect loops.
Would need more thought on this. Won't commit that patch yet but if that patch is useful if you want it offline etc, go ahead.
from ahx-web-player.
Hi Bryc! Wow that was quick ;-) Many thanks. Curious what the downside could be, but for now it's great! I'll try to create/add a timer of some sort.....if song is played for more than 5 minutes....we consider it's looping and we go to the next song ;-)
from ahx-web-player.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ahx-web-player.