Bug 1451149 - P2. Don't fire the "stalled" event when using MSE. r=bryce
When using a media element with a Media Source, the resource fetching algorithm is to be called in "local" mode: https://www.w3.org/TR/media-source/#mediasource-attach "Continue the resource fetch algorithm by running the remaining "Otherwise (mode is local)" steps, with these clarifications" https://html.spec.whatwg.org/multipage/media.html#concept-media-load-resource Under the local mode, the steps that would cause the element to fire suspend, stalled or progress can never occur. We only prevent the stalled event to be fired, many websites rely on the progress event to be fired (such as when the init segment has been parsed). The HTML5 media spec will be amended to clearly indicate that progress is to be fired even with mediasource MozReview-Commit-ID: DkoQzoV0JzO
This commit is contained in:
@@ -5717,9 +5717,9 @@ HTMLMediaElement::CheckProgress(bool aHaveNewProgress)
|
||||
}
|
||||
|
||||
if (now - mDataTime >= TimeDuration::FromMilliseconds(STALL_MS)) {
|
||||
DispatchAsyncEvent(NS_LITERAL_STRING("stalled"));
|
||||
|
||||
if (mMediaSource) {
|
||||
if (!mMediaSource) {
|
||||
DispatchAsyncEvent(NS_LITERAL_STRING("stalled"));
|
||||
} else {
|
||||
ChangeDelayLoadStatus(false);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user