|
@@ -1,7 +1,7 @@
|
|
|
import APIClient from '../../../util/API/APIClient';
|
|
|
import Consts from '../../../util/Consts';
|
|
|
import Utils from '../../../util/Utils';
|
|
|
-import HlsVideoPlugin from '../../../util/HlsVideoPlugin';
|
|
|
+import EfunVideoPlayer from '../../../util/EfunVideoPlayer';
|
|
|
import {CommandBus, CMD_TYPE} from '../../../util/CommandBus';
|
|
|
|
|
|
function matchWare(wareList, wareId) {
|
|
@@ -208,10 +208,10 @@ class LessonScene extends scene {
|
|
|
window.efunbox.start();
|
|
|
this.videoPlayer = window.efunbox;
|
|
|
} else {
|
|
|
- const videoDom = `<video id="hls-video" controls autoplay>你的浏览器不支持视频播放</video>`;
|
|
|
+ const videoDom = `<div id="hls-video"></div>`;
|
|
|
document.getElementById('view-content').innerHTML = videoDom;
|
|
|
- this.videoPlayer = new HlsVideoPlugin();
|
|
|
- this.videoPlayer.initH5Player(url, 'hls-video');
|
|
|
+ this.videoPlayer = new EfunVideoPlayer();
|
|
|
+ this.videoPlayer.initPlayer(url, 'hls-video');
|
|
|
}
|
|
|
// 监控到初始化视频成功后暂停画面
|
|
|
this.timer = window.setInterval(() => {
|
|
@@ -255,8 +255,8 @@ class LessonScene extends scene {
|
|
|
} else {
|
|
|
const videoDom = `<video id="hls-video" controls>你的浏览器不支持视频播放</video>`;
|
|
|
document.getElementById('view-content').innerHTML = videoDom;
|
|
|
- this.videoPlayer = new HlsVideoPlugin();
|
|
|
- this.videoPlayer.initH5Player(playUrl, 'hls-video');
|
|
|
+ this.videoPlayer = new EfunVideoPlayer();
|
|
|
+ this.videoPlayer.initPlayer(playUrl, 'hls-video');
|
|
|
}
|
|
|
break;
|
|
|
case Consts.TYPE_IMAGE:
|