修改直播
parent
447675f580
commit
a15069b782
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<view class="h-full w-full">
|
<view class="h-full w-full">
|
||||||
<div ref="muiPlayer" style="width: 100%; height: 100%"></div>
|
<div ref="muiPlayer"></div>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
@ -48,7 +48,11 @@ export default {
|
||||||
autoplay: true,
|
autoplay: true,
|
||||||
muted: true,
|
muted: true,
|
||||||
parse: parse,
|
parse: parse,
|
||||||
pageHead:false,
|
pageHead: false,
|
||||||
|
width: '100%',
|
||||||
|
height: '100%',
|
||||||
|
autoFit:false,
|
||||||
|
objectFit: 'contain',
|
||||||
videoAttribute: [
|
videoAttribute: [
|
||||||
{
|
{
|
||||||
attrKey: 'webkit-playsinline',
|
attrKey: 'webkit-playsinline',
|
||||||
|
|
@ -71,9 +75,10 @@ export default {
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
let _video = this.mp.video()
|
||||||
|
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.mp.on('ready', (event) => {
|
this.mp.on('ready', (event) => {
|
||||||
let _video = this.mp.video()
|
|
||||||
_video.play()
|
_video.play()
|
||||||
_video.addEventListener('play', (e) => {
|
_video.addEventListener('play', (e) => {
|
||||||
//播放事件
|
//播放事件
|
||||||
|
|
@ -89,6 +94,4 @@ export default {
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss"></style>
|
||||||
|
|
||||||
</style>
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue