android 视频播放指定位置,【报Bug】uniapp 视频api seek方法 在APP中安卓端 无法跳转到指定的位置播放...

产品分类:

uniapp/App

PC开发环境操作系统:

Windows

PC开发环境操作系统版本号:

windows10 专业版

HBuilderX类型:

正式

HBuilderX版本号:

2.9.8

手机系统:

Android

手机系统版本号:

Android 10

手机厂商:

华为

手机机型:

JEF-AN20

页面类型:

vue

nvue编译模式:

fast

打包方式:

云端

项目创建方式:

HBuilderX

示例代码:

export default {

data() {

return {

VideoContext: {},

state: true,

currentTime: 0,

duration: 0,

videoId: '',

url: 'http://imgmyqx.ofbei.com/upload1/20201207/5a755bafd1ceee8b93196173e3d9d563.mp4'

}

},

onReady() {

this.videoId = Date.now() + Math.ceil(Math.random()*10000000)+"";

this.VideoContext = uni.createVideoContext(this.videoId);

},

onLoad() {

const info = uni.getSystemInfoSync();

this.width = info.windowWidth+'px';

this.height = info.windowHeight;

this.VideoContext.seek(18.299);

this.VideoContext.play();

},

methods: {

timeupdate(e) {

console.log(e.detail);

this.duration = e.detail.duration

this.currentTime = e.detail.currentTime

},

pause(e) {

console.log('e--pause:'+JSON.stringify(e));

},

fullscreenchange(e) {

console.log('e--fullscreenchange:'+JSON.stringify(e));

},

exitFullScreen(e) {

console.log('e--exitFullScreen'+JSON.stringify(e));

}

}

}

操作步骤:

云端打包后,观察现象,看是否符合预期。

预期结果:

能够在指定的时间位置播放

实际结果:

不能够在指定的时间位置播放

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值