|
|
@@ -65,7 +65,7 @@ |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { defineComponent, ref, reactive, toRefs, computed, watch, nextTick, onBeforeUnmount, onMounted } from 'vue' |
|
|
|
import { defineComponent, ref, reactive, toRefs, computed, watch, nextTick, onBeforeUnmount, onMounted, onUnmounted } from 'vue' |
|
|
|
import Underlay from './Underlay.vue' |
|
|
|
import ControlPanel from './ControlPanel.vue' |
|
|
|
import SpeedChart from './SpeedChart.vue' |
|
|
@@ -373,18 +373,12 @@ export default defineComponent({ |
|
|
|
} |
|
|
|
|
|
|
|
const clearTimer = () => { |
|
|
|
if (data.chartTimer) { |
|
|
|
clearInterval(data.chartTimer) |
|
|
|
data.chartTimer = null |
|
|
|
} |
|
|
|
if (data.liveTimer) { |
|
|
|
clearInterval(data.liveTimer) |
|
|
|
data.liveTimer = null |
|
|
|
} |
|
|
|
if (data.failTimer) { |
|
|
|
clearInterval(data.failTimer) |
|
|
|
data.failTimer = null |
|
|
|
} |
|
|
|
clearInterval(data.chartTimer) |
|
|
|
data.chartTimer = null |
|
|
|
clearInterval(data.liveTimer) |
|
|
|
data.liveTimer = null |
|
|
|
clearInterval(data.failTimer) |
|
|
|
data.failTimer = null |
|
|
|
} |
|
|
|
|
|
|
|
function handleVideoStatus(status) { |
|
|
@@ -405,6 +399,11 @@ export default defineComponent({ |
|
|
|
clearTimer() |
|
|
|
}) |
|
|
|
|
|
|
|
onUnmounted(() => { |
|
|
|
clearInterval(data.failTimer) |
|
|
|
data.failTimer = null |
|
|
|
}) |
|
|
|
|
|
|
|
return { |
|
|
|
containerRef, |
|
|
|
sideRef, |