From 5ee65020a59e0d7a202faa0c0b0ccd78a5fa1a5c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Nicol=C3=B2=20Ribaudo?= Set this element's is currently stalled to false. Abort any already-running instance of the resource selection algorithm for this
- element. Abort the overall resource selection of this element. Let pending tasks be a list of all tasks
from the media element's media element event task source in one of the
@@ -38792,6 +38790,9 @@ interface MediaError {
+ Set the media element's in-progress resource selection child
+ pointer to null. Set the element's ⌛ Otherwise, if the media element does not have an assigned media provider
object and does not have a
networkState attribute to
the NETWORK_NO_SOURCE value.src attribute, but does have a source element child, then
- let mode be children and let candidate
- be the first such source element child in tree order.
⌛ Otherwise, the media element has no assigned media provider
object and has neither a ⌛ Let pointer be a position defined by two adjacent nodes in the
- media element's child list, treating the start of the list (before the first
- child in the list, if any) and end of the list (after the last child in the list, if any) as
- nodes in their own right. One node is the node before pointer, and the
- other node is the node after pointer. Initially, let pointer be the position between the candidate node and the
- next node, if there are any, or the end of the list, if it is the last node. As nodes are inserted, removed, and moved into the media element,
- pointer must be updated as follows: ⌛ Set the media element's in-progress resource selection
+ child pointer to the position between the start of media element's child
+ list and its first child. Other changes don't affect pointer. ⌛ Continue the resource selection algorithm for children given the
+ media element. ⌛ Process candidate: If candidate does not have a
- End the synchronous section, wait for continue the resource
+ selection algorithm for children's parallel steps to
+ complete, and continue the remaining steps in parallel. ⌛ If candidate has a Return. The element won't attempt to load another resource until either this algorithm
+ or continue the resource selection algorithm for children are triggered
+ again. ⌛ Let urlRecord be the result of encoding-parsing a URL
- given candidate's The dedicated media source failure steps with a list of promises
+ promises are the following steps: ⌛ If urlRecord is failure, then end the synchronous
- section, and jump down to the failed with elements step below. Set the ⌛ If candidate has a Forget the media element's media-resource-specific tracks. ⌛ Set the Set the element's End the synchronous section, continuing the remaining steps
- in parallel. Set the element's show poster flag to true. Run the resource fetch algorithm
- with urlRecord. If that algorithm returns without aborting this one,
- then the load failed. Fire an event named Failed with elements: Queue a media element task given the
- media element to fire an event named
- Reject pending play promises with promises and a
+ " Await a stable state. The synchronous section
- consists of all the remaining steps of this algorithm until the algorithm says the
- synchronous section has ended. (Steps in synchronous sections are marked with ⌛.) Set the element's delaying-the-load-event flag to false. This stops delaying the load event. ⌛ Forget the media element's media-resource-specific
- tracks. To abort the overall resource selection of a media element, abort its
+ resource selection algorithm, if running, and
+ any continue the resource selection algorithm for children invocation running for it,
+ together with any resource fetch algorithm
+ invoked therein, and set the media element's in-progress resource selection
+ child pointer to null. ⌛ Find next candidate: Let candidate be
- null. To continue the resource selection algorithm for children given a media
+ element: ⌛ Search loop: If the node after pointer is
- the end of the list, then jump to the waiting step below. Let pointer be the media element's in-progress resource
+ selection child pointer. ⌛ If the node after pointer is a Let candidate be null. ⌛ Advance pointer so that the node before pointer is now the node that was after pointer, and the node
- after pointer is the node after the node that used to be after pointer, if any. While candidate is not a ⌛ If candidate is null, jump back to the search
- loop step. Otherwise, jump back to the process candidate step. Set candidate to the node after pointer. ⌛ Waiting: Set the element's Advance pointer to the position between candidate and the next
+ node (or the end of the list). ⌛ Set the element's show poster flag to true. Set the media element's in-progress resource selection child
+ pointer to pointer. ⌛ Queue a media element task given the media element
- to set the element's delaying-the-load-event flag to false. This stops delaying the load event. If candidate is not a End the synchronous section, continuing the remaining steps
- in parallel. Set the media element's Wait until the node after pointer is a node other than the end of
- the list. (This step might wait forever.) Set the media element's show poster flag to true. Await a stable state. The synchronous section
- consists of all the remaining steps of this algorithm until the algorithm says the
- synchronous section has ended. (Steps in synchronous sections are marked with ⌛.) Queue a media element task given the media element to set the
+ media element's delaying-the-load-event flag to false. This stops
+ delaying the load event. ⌛ Set the element's delaying-the-load-event flag back to true (this
- delays the load event again, in case it hasn't been
- fired yet). ⌛ Set the Let urlRecord be the media source child url record of
+ candidate. ⌛ Jump back to the find next candidate step above. If urlRecord is not failure, set the The dedicated media source failure steps with a list of promises
- promises are the following steps: Run the following steps in parallel: Set the If urlRecord is not failure, run the resource fetch algorithm with urlRecord.
+ If that algorithm returns without aborting this one, then the load failed. Forget the media element's media-resource-specific tracks. Queue a media element task given the media element to fire an event named Set the element's Await a stable state. The synchronous section consists of all
+ the remaining steps of this algorithm until the algorithm says the synchronous
+ section has ended. (Steps in synchronous
+ sections are marked with ⌛.) Set the element's show poster flag to true. ⌛ Forget the media element's media-resource-specific tracks. Fire an event named ⌛ Continue the resource selection algorithm for children given the
+ media element. Reject pending play promises with promises and a
- " End the synchronous section, and wait for continue the resource
+ selection algorithm for children's parallel steps to
+ complete. Set the element's delaying-the-load-event flag to false. This stops delaying the load event. A media element has an in-progress resource
+ selection child pointer, which is either null or a position
+ defined by two adjacent nodes in the media element's
+ child list, treating the start of the list (before the first child
+ in the list, if any) and end of the list (after the last child in
+ the list, if any) as nodes in their own right. One node is the node
+ before the pointer, and the other node is the node after the
+ pointer. It is initially null. As nodes are inserted, removed, and moved into the media element, its
+ in-progress resource selection child pointer, if non-null, must be updated as
+ follows: Set the in-progress resource selection child pointer to the point between
+ the node before the pointer and the new node. In other words, insertions at the pointer go
+ after the pointer. Await a stable state. The synchronous section consists of all
+ the remaining steps of this algorithm. (Steps in the synchronous section are marked
+ with ⌛.) ⌛ If the media element's This happens when the continue the resource selection algorithm for
+ children terminated due to having tried all the ⌛ Set the media element's delaying-the-load-event flag back to
+ true (this delays the load event again, in case it
+ hasn't been fired yet). ⌛ Set the media element's ⌛ Run the continue the resource selection algorithm for children given the
+ media element. To get the media source child url record of a If any of the following conditions is true: candidate does not have a candidate's or candidate has a then return failure. Let urlRecord be the result of encoding-parsing a URL
+ given candidate's If urlRecord is failure, return failure. If candidate has a Return urlRecord. Fire an event named Abort the overall resource selection
- algorithm. Abort the overall resource selection of the media
+ element. Fire an event named Abort the overall resource selection
- algorithm. Abort the overall resource selection of the media
+ element. Set the element's delaying-the-load-event flag to false. This stops delaying the load event. Abort the overall resource selection
- algorithm. Abort the overall resource selection of the media element. Final step: If the user agent ever reaches this step (which can only happen if the entire resource
- gets loaded and kept available): abort the overall resource selection algorithm. Final step: If the user agent ever reaches this step (which can only happen if the
+ entire resource gets loaded and kept available): Abort the overall resource
+ selection of the media element.MediaError {
-
+
-
+ src attribute, or if its src attribute's value is the empty string, then end the
- synchronous section, and jump down to the failed with elements step
- below.media
- attribute whose value does not match the
- environment, then end the synchronous section, and jump down to the
- failed with elements step below.src attribute's value,
- relative to candidate's node document when the src attribute was last changed.
+
+
+
+
- error attribute to the result of
+ creating a MediaError with MEDIA_ERR_SRC_NOT_SUPPORTED.type attribute whose value, when parsed as a MIME
- type (including any codecs described by the codecs parameter, for
- types that define that parameter), represents a type that the user agent knows it cannot
- render, then end the synchronous section, and jump down to the failed with elements step below.currentSrc attribute to
- the result of applying the URL serializer to
- urlRecord.networkState attribute to
+ the NETWORK_NO_SOURCE value.error at the media element.error at candidate.NotSupportedError" DOMException.
+
-
-
+ source element,
- let candidate be that element.source element
+ and the node after pointer is not the end of the list:
+
+
- networkState attribute to the NETWORK_NO_SOURCE value.source element:
+
+
- networkState attribute to the NETWORK_NO_SOURCE value.networkState back to NETWORK_LOADING.currentSrc attribute to the result of applying the URL serializer to urlRecord.
-
+ error attribute to the result of
- creating a MediaError with MEDIA_ERR_SRC_NOT_SUPPORTED.error at candidate.networkState attribute to
- the NETWORK_NO_SOURCE value.error at the media element.NotSupportedError" DOMException.
+
+
+
+ networkState is NETWORK_NO_SOURCE:source elements and not
+ having found a suitable one. There is no other resource selection algorithm or continue
+ the resource selection algorithm for children currently running for this media
+ element.
+
+ networkState to NETWORK_LOADING.source element
+ candidate, run these steps. They return failure or a URL record.
+
+
+
+ src
+ attribute;src attribute's value is
+ the empty string;media attribute
+ whose value does not match the
+ environment,src attribute's value,
+ relative to candidate's node document when the src attribute was last changed.type attribute
+ whose value, when parsed as a MIME type (including any codecs described by the
+ codecs parameter, for types that define that parameter), represents
+ a type that the user agent knows it cannot render, return failure.error at the media element.error at the media element.