bugfix
This commit is contained in:
parent
1e2657ea2d
commit
48314a0bd1
@ -5,10 +5,7 @@
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<link rel="stylesheet" href="/bricks/3parties/xterm.css" />
|
||||
<link href="https://unpkg.com/video.js@6/dist/video-js.css" rel="stylesheet">
|
||||
<!---
|
||||
<link href="/bricks/3parties/video-js.css" rel="stylesheet" />
|
||||
--->
|
||||
<link rel="stylesheet" href="/bricks/css/bricks.css">
|
||||
</head>
|
||||
<body>
|
||||
@ -22,10 +19,11 @@
|
||||
|
||||
<script src="/bricks/3parties/marked.min.js"></script>
|
||||
<script src="/bricks/3parties/xterm.js"></script>
|
||||
<!---
|
||||
<script src="/bricks/3parties/video.min.js"></script>
|
||||
--->
|
||||
<!---
|
||||
<link href="https://unpkg.com/video.js@6/dist/video-js.css" rel="stylesheet">
|
||||
<script src="https://unpkg.com/video.js@6/dist/video.js"></script></head>
|
||||
--->
|
||||
|
||||
<script src="/bricks/3parties/recorder.wav.min.js"></script>
|
||||
<script src="/bricks/bricks.js"></script>
|
||||
|
@ -72,6 +72,14 @@ bricks.Video = class extends bricks.Layout {
|
||||
console.log('Video:play() called....');
|
||||
this.player.play();
|
||||
}
|
||||
set_fullscreen(){
|
||||
var co = this.player.getChild('FullscreenToggle');
|
||||
if (!co){
|
||||
console.log('video.js can not found FullscreenToggle');
|
||||
return;
|
||||
}
|
||||
co.trigger('click');
|
||||
}
|
||||
create_player(){
|
||||
if(this.url){
|
||||
this.player = videojs(this.video_body.dom_element, {
|
||||
@ -86,6 +94,7 @@ bricks.Video = class extends bricks.Layout {
|
||||
this.player.on('play', this.report_playok.bind(this));
|
||||
this.player.on('ended', this.report_ended.bind(this));
|
||||
this._set_source();
|
||||
this.player.ready(this.set_fullscreen.bind(this));
|
||||
/*
|
||||
if (this.autoplay){
|
||||
this.player.autoplay = true;
|
||||
|
Loading…
Reference in New Issue
Block a user