@gcorevideo/player 2.28.10 → 2.28.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core.js +16 -15
- package/dist/index.css +212 -212
- package/dist/index.embed.js +15 -14
- package/dist/index.js +16 -15
- package/lib/playback/HTML5Video.d.ts.map +1 -1
- package/lib/playback/HTML5Video.js +15 -14
- package/package.json +1 -1
- package/src/playback/HTML5Video.ts +15 -14
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -48,21 +48,22 @@ export default class HTML5Video extends BasePlayback {
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
override _handleBufferingEvents() {
|
|
51
|
-
// TODO use the logic from the base class to detect if it's stalled or resumed, because in the latter case the current behavior is not correct
|
|
52
|
-
if (!this.stallTimerId) {
|
|
53
|
-
this.stallTimerId = setTimeout(() => {
|
|
54
|
-
this.stallTimerId = null
|
|
55
|
-
const error = this.createError({
|
|
56
|
-
code: PlaybackErrorCode.MediaSourceUnavailable,
|
|
57
|
-
level: PlayerError.Levels.FATAL,
|
|
58
|
-
message: 'Stall timeout',
|
|
59
|
-
description: 'Playback stalled for too long',
|
|
60
|
-
})
|
|
61
|
-
this.trigger(ClapprEvents.PLAYBACK_ERROR, error)
|
|
62
|
-
setTimeout(() => this.stop(), 0)
|
|
63
|
-
}, STALL_TIMEOUT)
|
|
64
|
-
}
|
|
65
51
|
super._handleBufferingEvents()
|
|
52
|
+
// TODO test case: playback stalled and then resumed. The should be no MediaSourceUnavailable/"Stall timeout" error
|
|
53
|
+
if (!this._isBuffering || this.stallTimerId) {
|
|
54
|
+
return
|
|
55
|
+
}
|
|
56
|
+
this.stallTimerId = setTimeout(() => {
|
|
57
|
+
this.stallTimerId = null
|
|
58
|
+
const error = this.createError({
|
|
59
|
+
code: PlaybackErrorCode.MediaSourceUnavailable,
|
|
60
|
+
level: PlayerError.Levels.FATAL,
|
|
61
|
+
message: 'Stall timeout',
|
|
62
|
+
description: 'Playback stalled for too long',
|
|
63
|
+
})
|
|
64
|
+
this.trigger(ClapprEvents.PLAYBACK_ERROR, error)
|
|
65
|
+
setTimeout(() => this.stop(), 0)
|
|
66
|
+
}, STALL_TIMEOUT)
|
|
66
67
|
}
|
|
67
68
|
|
|
68
69
|
override _onPlaying() {
|