mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-11 13:56:15 -08:00
判断控制器是否可用
This commit is contained in:
1 parent
cc078f0ebc
commit
cc7e489ff6
5 files changed
+35
-20
No files matched your search
@@ -15,8 +15,14 @@ export default class Controls {
|
||||
constructor(art) {
|
||||
this.art = art;
|
||||
this.$map = {};
|
||||
this.init();
|
||||
this.mount();
|
||||
this.isVideoCanplay = false;
|
||||
this.art.on('video:canplay', () => {
|
||||
if (!this.isVideoCanplay) {
|
||||
this.isVideoCanplay = true;
|
||||
this.init();
|
||||
this.mount();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
init() {
|
||||
|
||||
Reference in new issue
Block a user