mirror of
https://github.com/john-okeefe/foliate-js.git
synced 2026-09-09 11:29:14 -04:00
EPUB: fix media overlay playback
For some reason `canplaythrough` is firing more than once
This commit is contained in:
@@ -486,7 +486,7 @@ class MediaOverlay extends EventTarget {
|
|||||||
audio.volume = this.#volume
|
audio.volume = this.#volume
|
||||||
audio.playbackRate = this.#rate
|
audio.playbackRate = this.#rate
|
||||||
audio.play().catch(e => this.#error(e))
|
audio.play().catch(e => this.#error(e))
|
||||||
})
|
}, { once: true })
|
||||||
}
|
}
|
||||||
async start(sectionIndex, filter = () => true) {
|
async start(sectionIndex, filter = () => true) {
|
||||||
this.#audio?.pause()
|
this.#audio?.pause()
|
||||||
|
|||||||
Reference in New Issue
Block a user