提交 57846b94 编写于 作者: W wanganxp

开启video的cache

上级 125cc859
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<swiper-item class="swiper-item" v-for="(item,i) in visibleList" :key="i"> <swiper-item class="swiper-item" v-for="(item,i) in visibleList" :key="i">
<video @click="changeState(i)" ref="video" class="video-box" objectFit="cover" :id="'video-'+i" <video @click="changeState(i)" ref="video" class="video-box" objectFit="cover" :id="'video-'+i"
@loadstart="onLoadstart(i)" :src="item.src" :poster="item.poster_src" :autoplay="false" @loadstart="onLoadstart(i)" :src="item.src" :poster="item.poster_src" :autoplay="false"
:show-center-play-btn="false" :loop="true" @play="onPlay(i)" @pause="onPause(i)"></video> :show-center-play-btn="false" :loop="true" @play="onPlay(i)" @pause="onPause(i)" http-cache="true"></video>
<view class="video-cover" @click="changeState(i)"> <view class="video-cover" @click="changeState(i)">
<image v-if="state[i] === 'pause'" class="play-btn" src="/static/template/swiper-vertical-video/play.png" <image v-if="state[i] === 'pause'" class="play-btn" src="/static/template/swiper-vertical-video/play.png"
mode="widthFix"></image> mode="widthFix"></image>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册