Browse Source

定时器

y595705120 2 months ago
parent
commit
24c4fe642f
1 changed files with 4 additions and 0 deletions
  1. 4 0
      src/containers/center/play/components/media.vue

+ 4 - 0
src/containers/center/play/components/media.vue

@@ -59,6 +59,7 @@
     created() {
       this.timer = setInterval(this.tick, 5 * 1000);
       this.startMonitor();
+      this.updateBlurtime()
     },
     methods: {
       playerReadied(player) {
@@ -96,11 +97,14 @@
       },
       onPlayerPause(event) {
         this.onPlay = false
+        this.updateBlurtime()
       },
       onPlayerEnded( event ){
+        this.updateBlurtime()
         this.tick( true )
       },
       doPause( ){
+        this.updateBlurtime()
         let myPlayer = this.$refs.videoPlayer.player;
         myPlayer && myPlayer.pause()
         console.log("doPause", myPlayer)