合并master代码
This commit is contained in:
@@ -515,7 +515,7 @@
|
|||||||
|
|
||||||
},
|
},
|
||||||
async receiveisSetFirstTime(newValue, oldValue, ownerVm, vm) {
|
async receiveisSetFirstTime(newValue, oldValue, ownerVm, vm) {
|
||||||
console.log('是否刚开始设置播放时间', newValue, this.firstTime, this.player);
|
console.log('是否刚开始设置播放时间', newValue, this.firstTime, myplayer);
|
||||||
},
|
},
|
||||||
emitSetData(event, ownerInstance) {
|
emitSetData(event, ownerInstance) {
|
||||||
// var that = this;
|
// var that = this;
|
||||||
@@ -538,7 +538,7 @@
|
|||||||
changeVideoScreen(event, ownerInstance) {
|
changeVideoScreen(event, ownerInstance) {
|
||||||
var that = this;
|
var that = this;
|
||||||
// this.$emit('changeScreenLoading',true)
|
// this.$emit('changeScreenLoading',true)
|
||||||
var status = this.player.fullscreenService.getIsFullScreen();
|
var status = myplayer.fullscreenService.getIsFullScreen();
|
||||||
console.log('this.$platform--------', this.platform);
|
console.log('this.$platform--------', this.platform);
|
||||||
if (this.platform != 'ios') { // 改变按钮形态
|
if (this.platform != 'ios') { // 改变按钮形态
|
||||||
ownerInstance.callMethod('screenChange', {
|
ownerInstance.callMethod('screenChange', {
|
||||||
@@ -551,11 +551,11 @@
|
|||||||
console.log('恢复竖版');
|
console.log('恢复竖版');
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
plus.screen.lockOrientation("portrait-primary"); //锁死屏幕方向为竖屏
|
plus.screen.lockOrientation("portrait-primary"); //锁死屏幕方向为竖屏
|
||||||
this.player.fullscreenService.cancelFullScreen();
|
myplayer.fullscreenService.cancelFullScreen();
|
||||||
}, 100);
|
}, 100);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.player.fullscreenService.requestFullScreen();
|
myplayer.fullscreenService.requestFullScreen();
|
||||||
if (this.platform != 'ios') {
|
if (this.platform != 'ios') {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
plus.screen.lockOrientation("landscape-primary");
|
plus.screen.lockOrientation("landscape-primary");
|
||||||
@@ -577,16 +577,9 @@
|
|||||||
// renderjs阿里云播放器引入与配置
|
// renderjs阿里云播放器引入与配置
|
||||||
getLive() {
|
getLive() {
|
||||||
console.log('这是这只只是666666:', this.firstTime, this.videoData)
|
console.log('这是这只只是666666:', this.firstTime, this.videoData)
|
||||||
if (this.player) {
|
|
||||||
this.player.pause();
|
|
||||||
myplayer.pause()
|
|
||||||
this.player.dispose();
|
|
||||||
$('#url-player-test').empty();
|
$('#url-player-test').empty();
|
||||||
this.player = null;
|
|
||||||
myplayer = undefined
|
|
||||||
|
|
||||||
console.log('上一条视频的状态,',this.player.getStatus());
|
|
||||||
}
|
|
||||||
pauseTime = 0
|
pauseTime = 0
|
||||||
var fullScreenButtonComponent = Aliplayer.Component({
|
var fullScreenButtonComponent = Aliplayer.Component({
|
||||||
/**
|
/**
|
||||||
@@ -614,21 +607,6 @@
|
|||||||
});
|
});
|
||||||
$(el).find('.prism-time-display').after(this.$html);
|
$(el).find('.prism-time-display').after(this.$html);
|
||||||
},
|
},
|
||||||
ready: function(player, e) {
|
|
||||||
// this.$html.hide()
|
|
||||||
},
|
|
||||||
/**
|
|
||||||
* 隐藏广告
|
|
||||||
*/
|
|
||||||
play: function(player, e) {
|
|
||||||
// this.$html.show();
|
|
||||||
},
|
|
||||||
/**
|
|
||||||
* 显示广告
|
|
||||||
*/
|
|
||||||
pause: function(player, e) {
|
|
||||||
// this.$html.show();
|
|
||||||
},
|
|
||||||
/**
|
/**
|
||||||
* 隐藏广告
|
* 隐藏广告
|
||||||
*/
|
*/
|
||||||
@@ -636,15 +614,7 @@
|
|||||||
this.$html.show();
|
this.$html.show();
|
||||||
// this.$html.hide();
|
// this.$html.hide();
|
||||||
},
|
},
|
||||||
waiting: function(player, e) {
|
|
||||||
// this.$html.hide()
|
|
||||||
},
|
|
||||||
timeupdate: function(player, e) {},
|
|
||||||
error: function(player, e) {},
|
|
||||||
/**
|
|
||||||
* 显示广告
|
|
||||||
*/
|
|
||||||
ended: function(player, e) {}
|
|
||||||
});
|
});
|
||||||
// console.log('这是查看是否获取到hlstoken', this.videoData)
|
// console.log('这是查看是否获取到hlstoken', this.videoData)
|
||||||
var playerOptions = {
|
var playerOptions = {
|
||||||
@@ -782,7 +752,7 @@
|
|||||||
this.player = player;
|
this.player = player;
|
||||||
myplayer = player;
|
myplayer = player;
|
||||||
// console.log('myplayer------------',myplayer.loadByUrl('https://www.w3schools.com/html/movie.mp4'));
|
// console.log('myplayer------------',myplayer.loadByUrl('https://www.w3schools.com/html/movie.mp4'));
|
||||||
console.log('是否拿到第一次初始值呢', this.platform, typeof this.firstTime, this.firstTime)
|
// console.log('是否拿到第一次初始值呢', this.platform, typeof this.firstTime, this.firstTime)
|
||||||
|
|
||||||
player.on('ready', function() {
|
player.on('ready', function() {
|
||||||
console.log('播放器准备就绪,开始播放');
|
console.log('播放器准备就绪,开始播放');
|
||||||
@@ -812,12 +782,12 @@
|
|||||||
}
|
}
|
||||||
//}
|
//}
|
||||||
})
|
})
|
||||||
this.player.on('playing', function() {
|
myplayer.on('playing', function() {
|
||||||
console.log('正在播放...')
|
console.log('正在播放...')
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
this.player.on('timeupdate', function() {
|
myplayer.on('timeupdate', function() {
|
||||||
let that = this
|
let that = this
|
||||||
var _time = parseInt(player.getCurrentTime())
|
var _time = parseInt(player.getCurrentTime())
|
||||||
curStatus = player.getStatus()
|
curStatus = player.getStatus()
|
||||||
@@ -833,7 +803,7 @@
|
|||||||
$('.videoContent1').click()
|
$('.videoContent1').click()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.player.on('ended', function() {
|
myplayer.on('ended', function() {
|
||||||
console.log('播放完毕');
|
console.log('播放完毕');
|
||||||
$('.videoContent2').click()
|
$('.videoContent2').click()
|
||||||
$('.videoContent6').click()
|
$('.videoContent6').click()
|
||||||
@@ -844,7 +814,7 @@
|
|||||||
console.log('触发暂停', pauseTime)
|
console.log('触发暂停', pauseTime)
|
||||||
})
|
})
|
||||||
|
|
||||||
this.player.on('error', function() {
|
myplayer.on('error', function() {
|
||||||
console.log('播放出错')
|
console.log('播放出错')
|
||||||
$('.videoContent5').click()
|
$('.videoContent5').click()
|
||||||
})
|
})
|
||||||
@@ -878,11 +848,11 @@
|
|||||||
receiveScreenType(newValue) {},
|
receiveScreenType(newValue) {},
|
||||||
async receiveIsfresh(newValue) {
|
async receiveIsfresh(newValue) {
|
||||||
|
|
||||||
console.log('是否走了刷新销毁方法:', this.player)
|
console.log('是否走了刷新销毁方法:', myplayer)
|
||||||
if (this.player) {
|
if (myplayer) {
|
||||||
// clearInterval(this.$store.state.videoTimer)
|
// clearInterval(this.$store.state.videoTimer)
|
||||||
// await this.setVideoTime();
|
// await this.setVideoTime();
|
||||||
this.player.dispose();
|
myplayer.dispose();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async receiveplatform(newValue) {
|
async receiveplatform(newValue) {
|
||||||
|
|||||||
@@ -2192,7 +2192,7 @@
|
|||||||
/deep/.u-icon__icon--warning {
|
/deep/.u-icon__icon--warning {
|
||||||
color: #fff !important;
|
color: #fff !important;
|
||||||
}
|
}
|
||||||
|
/deep/.uni-tag{border-width: 2rpx !important;}
|
||||||
/deep/.uni-section {
|
/deep/.uni-section {
|
||||||
background: transparent !important;
|
background: transparent !important;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user