mirror of
https://github.com/9001/copyparty.git
synced 2025-08-18 01:22:13 -06:00
media-player: play links don't scroll on click
This commit is contained in:
parent
93ed0fc10b
commit
2163055dae
|
@ -8,7 +8,14 @@ function dbg(msg) {
|
||||||
|
|
||||||
function ev(e) {
|
function ev(e) {
|
||||||
e = e || window.event;
|
e = e || window.event;
|
||||||
e.preventDefault ? e.preventDefault() : (e.returnValue = false);
|
|
||||||
|
if (e.preventDefault)
|
||||||
|
e.preventDefault()
|
||||||
|
|
||||||
|
if (e.stopPropagation)
|
||||||
|
e.stopPropagation();
|
||||||
|
|
||||||
|
e.returnValue = false;
|
||||||
return e;
|
return e;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -447,7 +454,8 @@ function play(tid, call_depth) {
|
||||||
mp.au.tid = tid;
|
mp.au.tid = tid;
|
||||||
mp.au.src = url;
|
mp.au.src = url;
|
||||||
mp.au.volume = mp.expvol();
|
mp.au.volume = mp.expvol();
|
||||||
setclass('trk' + tid, 'play act');
|
var oid = 'trk' + tid;
|
||||||
|
setclass(oid, 'play act');
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if (hack_attempt_play)
|
if (hack_attempt_play)
|
||||||
|
@ -456,7 +464,11 @@ function play(tid, call_depth) {
|
||||||
if (mp.au.paused)
|
if (mp.au.paused)
|
||||||
autoplay_blocked();
|
autoplay_blocked();
|
||||||
|
|
||||||
location.hash = 'trk' + tid;
|
var o = ebi(oid);
|
||||||
|
o.setAttribute('id', 'thx_js');
|
||||||
|
location.hash = oid;
|
||||||
|
o.setAttribute('id', oid);
|
||||||
|
|
||||||
pbar.drawbuf();
|
pbar.drawbuf();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue