1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="IE=edge" >
<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no"/>
<title>Aliplay记忆播放器</title>
<link rel="stylesheet" href="https://g.alicdn.com/de/prismplayer/2.8.7/skins/default/aliplayer-min.css" />
<script type="text/javascript" charset="utf-8" src="https://g.alicdn.com/de/prismplayer/2.8.7/aliplayer-min.js"></script>
<script type="text/javascript" charset="utf-8" src="https://player.alicdn.com/aliplayer/presentation/js/aliplayercomponents.min.js"></script>
<style type="text/css">
body,html{background-color:#000;padding: 0;margin: 0;width:100%;height:100%;}
#liryCN{width:100%;height:100%;padding:0;margin:0;display:block;}
</style>
</head>
<body>
<div id="liryCN" class="prism-player"></div>
<script type="text/javascript">
var player = new Aliplayer({
id: "liryCN",
"source": parent.MacPlayer.PlayUrl,
width: "100%",
height: "100%",
autoplay: true,
preload: true,
rePlay: false,
playsinline: false,
useH5Prism: false,
isLive: false,
autoPlayDelay: 0,
autoPlayDelayDisplayText: 'YY影院,请稍待正在加载...',
components: [{
name: 'MemoryPlayComponent',
type: AliPlayerComponent.MemoryPlayComponent,
args: [true]
}],
},
function (player) {
player.play();
}
);
player.on('ended',function(){
if(parent.MacPlayer.PlayLinkNext!=''){
top.location.href = parent.MacPlayer.PlayLinkNext;
}
});
var _video = document.querySelector('video');
player.on('play', function(e) {
_video.removeEventListener('click', play);
_video.addEventListener('click', pause);
});
player.on('pause', function(e) {
_video.removeEventListener('click', pause);
_video.addEventListener('click', play)
});
function play() {
if (player) player.play();
}
function pause() {
if (player) player.pause();
}
try{
//document.getElementById('liryCN').style.height = parent.MacPlayer.Height + 'px';
}
catch(e){}
</script>
</body>
</html>
|