summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2019-05-23 11:22:59 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2019-05-23 11:22:59 +0800
commit66a5e6cdea1c4ac875a1562ba91072146e7ecc47 (patch)
treedea48f072e42aa640a4c2b91673b9c6ed19490e8 /libs
parentb55921331fa152836694a7f8cce83a9fe00c7670 (diff)
downloadweb-66a5e6cdea1c4ac875a1562ba91072146e7ecc47.tar.xz
new download repository and link to m3u8 playlist.
Diffstat (limited to 'libs')
-rw-r--r--libs/music/player5
-rw-r--r--libs/music/player.d/main_static.js3
2 files changed, 6 insertions, 2 deletions
diff --git a/libs/music/player b/libs/music/player
index a64b0fa..8ce5871 100644
--- a/libs/music/player
+++ b/libs/music/player
@@ -126,7 +126,7 @@ The online player was added.
<li><a href="/"><h1>Chrisoft</h1></a></li>
<li><a href="/libs/music/player"><h2>Music Library</h2></a></li>
<li><ul id="plists"></ul></li>
- <li><a href="/libs/music/">Downloads</a></li>
+ <li><a href="//filestorage.chrisoft.org/music/" target="_blank">Downloads</a></li>
<li><a>TSOP 2.5.3</a></li>
</ul>
</div>
@@ -139,7 +139,8 @@ The online player was added.
<div id="ctrlcontainer" class="footer TText widgetbg">
<div class="switches" style="text-align:right;padding-top:0.25em 0 0.25em 0;">
<div style="text-align:center;width:100%;" id="nowplaying"></div>
- <a id="plistsw" href="javascript:void(0);">[Hide Playlist]</a >
+ <a id="am3u8" href="#">[m3u8 Playlist]</a>
+ <a id="plistsw" href="javascript:void(0);">[Hide Playlist]</a>
</div>
<div class="centered-audio">
<audio id="audio" preload="auto" tabindex="0" type="audio/ogg" autoplay="autoplay" style="display:none;" crossorigin="anonymous"></audio>
diff --git a/libs/music/player.d/main_static.js b/libs/music/player.d/main_static.js
index 9354375..311aa99 100644
--- a/libs/music/player.d/main_static.js
+++ b/libs/music/player.d/main_static.js
@@ -134,6 +134,7 @@ NSUI={
pbnext:null,
pbprev:null,
ctrlcontainer:null,
+ am3u8:null,
bplayrect:"0 -48px",
bpauserect:"-24px -48px",
brallrect:"-24px -24px",
@@ -165,6 +166,7 @@ NSUI={
this.pbnext=sh.elem('pbnext');
this.pbprev=sh.elem('pbprev');
this.ctrlcontainer=sh.elem('ctrlcontainer');
+ this.am3u8=sh.elem('am3u8');
NSUI.canvas.width=NSUI.canvas.clientWidth*window.devicePixelRatio;
NSUI.canvas.height=NSUI.canvas.clientHeight*window.devicePixelRatio;
NSUI.vissel.onchange=function(){
@@ -299,6 +301,7 @@ NSUI={
const d=sh.newelem('div');d.style.height=`${NSUI.ctrlcontainer.getBoundingClientRect().height+16}px`;
this.playlist.appendChild(d);
this.selectedplist=this.playlists[id].plistname;
+ this.am3u8.href=`https://chrisoft.org/libs/music/player.d/cgi-bin/m3u8.cgi?plist=${this.playlists[id].plistname}`;
},
switch_playlist:function(pl,setactive)
{