|
|
|
@ -39,6 +39,18 @@ |
|
|
|
|
options.video.url = page.params.url; |
|
|
|
|
} |
|
|
|
|
const dp = new DPlayer(options); |
|
|
|
|
/* recover history playing */ |
|
|
|
|
if(options.video.url && options.video.url != 'https://api.yimian.xyz/video?path=404.mp4'){ |
|
|
|
|
if(cookie.get($.md5(options.video.url)) != null){ |
|
|
|
|
dp.seek(cookie.get($.md5(options.video.url))); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
/* record seek point */ |
|
|
|
|
setInterval(function(){ |
|
|
|
|
if(!dp.video.paused && dp.video.currentTime > 10){ |
|
|
|
|
cookie.set($.md5(options.video.url), dp.video.currentTime); |
|
|
|
|
} |
|
|
|
|
}, 1000); |
|
|
|
|
</script> |
|
|
|
|
</body> |
|
|
|
|
</html> |