修复 raw 模式下播放器文件大小无法统计,及 raw 模式错误调用 prepare
This commit is contained in:
@@ -577,7 +577,7 @@ const component_audio_player = {
|
|||||||
file() {
|
file() {
|
||||||
// 如果没有勾选 prepare 则直接播放
|
// 如果没有勾选 prepare 则直接播放
|
||||||
// 否则进入 prepare 流程
|
// 否则进入 prepare 流程
|
||||||
if (this.prepare) {
|
if (this.prepare && this.file.play_back_type === 'stream') {
|
||||||
this.prepare_func()
|
this.prepare_func()
|
||||||
} else {
|
} else {
|
||||||
this.playing_file = this.file
|
this.playing_file = this.file
|
||||||
@@ -599,6 +599,9 @@ const component_audio_player = {
|
|||||||
if (this.prepare) {
|
if (this.prepare) {
|
||||||
filesize = this.prepared_filesize
|
filesize = this.prepared_filesize
|
||||||
}
|
}
|
||||||
|
if (this.playing_file.play_back_type === 'raw') {
|
||||||
|
filesize = this.playing_file.filesize
|
||||||
|
}
|
||||||
if (filesize < 1024 * 1024) {
|
if (filesize < 1024 * 1024) {
|
||||||
return filesize
|
return filesize
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user