fix: 修复外显状态不一致问题
This commit is contained in:
parent
2ed26d587b
commit
2fdec7688b
|
@ -11,7 +11,7 @@ export const usePlayState = defineStore('playState', () => {
|
|||
const actualPlaying = ref(false) // 实际音频的播放与暂停
|
||||
|
||||
// 外显播放状态方法
|
||||
const playingState = computed(() => isPlaying.value || actualPlaying.value) // 其中有一个为 true 时回报为 true
|
||||
const playingState = computed(() => isPlaying.value)
|
||||
const playProgressState = computed(() => playProgress.value)
|
||||
const trackDurationState = computed(() => currentTrackDuration.value)
|
||||
const actualPlayingState = computed(() => actualPlaying.value)
|
||||
|
@ -64,6 +64,7 @@ export const usePlayState = defineStore('playState', () => {
|
|||
// 回报 Web Audio API 正在播放
|
||||
const reportActualPlaying = (playing: boolean) => {
|
||||
actualPlaying.value = playing
|
||||
if (playing) isPlaying.value = true
|
||||
}
|
||||
|
||||
return {
|
||||
|
|
Loading…
Reference in New Issue
Block a user