Skip to content

Commit 31666be

Browse files
dtapuskadomenic
authored andcommitted
Convert some "queue a task" to "queue an element task"
Helps with #4980 and #4506.
1 parent ef4d727 commit 31666be

File tree

1 file changed

+97
-69
lines changed

1 file changed

+97
-69
lines changed

source

Lines changed: 97 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -13921,8 +13921,9 @@ interface <dfn>HTMLLinkElement</dfn> : <span>HTMLElement</span> {
1392113921
be fetched and processed, with the expectation that this will be done correctly.</p>
1392213922
</li>
1392313923

13924-
<li><span>Queue a task</span> on the <span>networking task source</span> to <span>process the
13925-
linked resource</span> given <var>el</var>, <var>success</var>, and <var>response</var>.</li>
13924+
<li><span>Queue an element task</span> on the <span>networking task source</span> given
13925+
<var>el</var> to <span>process the linked resource</span> given <var>el</var>,
13926+
<var>success</var>, and <var>response</var>.</li>
1392613927
</ol>
1392713928
</li>
1392813929

@@ -15374,7 +15375,8 @@ interface <dfn>HTMLStyleElement</dfn> : <span>HTMLElement</span> {
1537415375
</li>
1537515376

1537615377
<li>
15377-
<p><span>Queue a task</span> on the <span>networking task source</span> to run these steps:</p>
15378+
<p><span>Queue an element task</span> on the <span>networking task source</span> given
15379+
<var>element</var> and the following steps:</p>
1537815380

1537915381
<ol>
1538015382
<li><p>If <var>success</var> is true, <span data-x="concept-event-fire">fire an event</span>
@@ -28285,10 +28287,18 @@ was an English &lt;a href="/wiki/Music_hall">music hall&lt;/a> singer, ...</code
2828528287

2828628288
<li><p>&#x231B; Set <span>pending request</span> to null.</p></li>
2828728289

28288-
<li><p>&#x231B; <span>Queue a task</span> to change the <span>current request</span>'s <span
28289-
data-x="img-req-url">current URL</span> to <var>selected source</var>, <span
28290-
data-x="concept-event-fire">fire an event</span> named <code data-x="event-error">error</code>
28291-
at the <code>img</code> element.</p></li>
28290+
<li>
28291+
<p>&#x231B; <span>Queue an element task</span> on the <span>DOM manipulation task
28292+
source</span> given the <code>img</code> element and the following steps:</p>
28293+
28294+
<ol>
28295+
<li><p>Change the <span>current request</span>'s <span data-x="img-req-url">current
28296+
URL</span> to <var>selected source</var>.</p></li>
28297+
28298+
<li><p><span data-x="concept-event-fire">Fire an event</span> named <code
28299+
data-x="event-error">error</code> at the <code>img</code> element.</p></li>
28300+
</ol>
28301+
</li>
2829228302

2829328303
<li><p>&#x231B; Return.</p></li>
2829428304
</ol>
@@ -29177,7 +29187,8 @@ was an English &lt;a href="/wiki/Music_hall">music hall&lt;/a> singer, ...</code
2917729187

2917829188
<li>
2917929189

29180-
<p><span>Queue a task</span> to run these steps:</p>
29190+
<p><span>Queue an element task</span> on the <span>DOM manipulation task source</span> given
29191+
the <code>img</code> element and the following steps:</p>
2918129192

2918229193
<ol>
2918329194

@@ -30410,10 +30421,8 @@ interface <dfn>HTMLIFrameElement</dfn> : <span>HTMLElement</span> {
3041030421

3041130422
<dd>
3041230423

30413-
<p><span>Queue a task</span> to run the <span>iframe load event steps</span>.</p>
30414-
30415-
<p>The <span>task source</span> for this <span data-x="concept-task">task</span> is the
30416-
<span>DOM manipulation task source</span>.</p>
30424+
<p><span>Queue an element task</span> on the <span>DOM manipulation task source</span> given
30425+
the <code>iframe</code> element and the <span>iframe load event steps</span>.</p>
3041730426

3041830427
</dd>
3041930428

@@ -33538,9 +33547,10 @@ interface <dfn>MediaError</dfn> {
3353833547

3353933548
<ol>
3354033549

33541-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span>
33542-
named <code data-x="event-media-emptied">emptied</code> at the <span>media
33543-
element</span>.</p></li>
33550+
<li><p><span>Queue an element task</span> on the <span>media element event task source</span>
33551+
given the <span>media element</span> to <span
33552+
data-x="concept-event-fire">fire an event</span> named <code
33553+
data-x="event-media-emptied">emptied</code> at the <span>media element</span>.</p></li>
3354433554

3354533555
<li><p>If a fetching process is in progress for the <span>media
3354633556
element</span>, the user agent should stop it.</p></li>
@@ -33689,9 +33699,10 @@ interface <dfn>MediaError</dfn> {
3368933699
data-x="dom-media-networkState">networkState</code> to <code
3369033700
data-x="dom-media-NETWORK_LOADING">NETWORK_LOADING</code>.</p></li>
3369133701

33692-
<li><p>&#x231B; <span>Queue a task</span> to <span data-x="concept-event-fire">fire an
33693-
event</span> named <code data-x="event-media-loadstart">loadstart</code> at the <span>media
33694-
element</span>.</p></li>
33702+
<li><p>&#x231B; <span>Queue an element task</span> on the <span>media element event task
33703+
source</span> given the <span>media element</span> to <span
33704+
data-x="concept-event-fire">fire an event</span> named <code
33705+
data-x="event-media-loadstart">loadstart</code> at the <span>media element</span>.</p></li>
3369533706

3369633707
<li>
3369733708

@@ -33848,9 +33859,10 @@ interface <dfn>MediaError</dfn> {
3384833859
with <var>urlRecord</var>. If that algorithm returns without aborting <em>this</em> one,
3384933860
then the load failed.</p></li>
3385033861

33851-
<li><p><i>Failed with elements</i>: <span>Queue a task</span> to <span
33862+
<li><p><i>Failed with elements</i>: <span>Queue an element task</span> on the <span>media
33863+
element event task source</span> given <var>candidate</var> to <span
3385233864
data-x="concept-event-fire">fire an event</span> named <code
33853-
data-x="event-source-error">error</code> at the <var>candidate</var> element.</p></li>
33865+
data-x="event-source-error">error</code> at <var>candidate</var>.</p></li>
3385433866

3385533867
<li><p><span>Await a stable state</span>. The <span>synchronous section</span>
3385633868
consists of all the remaining steps of this algorithm until the algorithm says the
@@ -33881,7 +33893,8 @@ interface <dfn>MediaError</dfn> {
3388133893

3388233894
<li><p>&#x231B; Set the element's <span>show poster flag</span> to true.</p></li>
3388333895

33884-
<li><p>&#x231B; <span>Queue a task</span> to set the element's <span>delaying-the-load-event
33896+
<li><p>&#x231B; <span>Queue an element task</span> on the <span>media element event task
33897+
source</span> given the element to set the element's <span>delaying-the-load-event
3388533898
flag</span> to false. This stops <span data-x="delay the load event">delaying the load
3388633899
event</span>.</p></li>
3388733900

@@ -33988,11 +34001,13 @@ interface <dfn>MediaError</dfn> {
3398834001
<li><p>Set the <code data-x="dom-media-networkState">networkState</code> to <code
3398934002
data-x="dom-media-NETWORK_IDLE">NETWORK_IDLE</code>.</p></li>
3399034003

33991-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span>
34004+
<li><p><span>Queue an element task</span> on the <span>media element event task
34005+
source</span> given the element to <span data-x="concept-event-fire">fire an event</span>
3399234006
named <code data-x="event-media-suspend">suspend</code> at the element.</p></li>
3399334007

33994-
<li><p><span>Queue a task</span> to set the element's <span>delaying-the-load-event flag</span>
33995-
to false. This stops <span data-x="delay the load event">delaying the load
34008+
<li><p><span>Queue an element task</span> on the <span>media element event task
34009+
source</span> given the element to set the element's <span>delaying-the-load-event
34010+
flag</span> to false. This stops <span data-x="delay the load event">delaying the load
3399634011
event</span>.</p></li>
3399734012

3399834013
<li><p>Wait for the task to be run.</p></li>
@@ -35075,8 +35090,9 @@ interface <dfn>MediaError</dfn> {
3507535090

3507635091
<dd id="fire-loadedmetadata">
3507735092

35078-
<p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
35079-
<code data-x="event-media-loadedmetadata">loadedmetadata</code> at the element.</p>
35093+
<p><span>Queue an element task</span> on the <span>media element event task source</span>
35094+
given the element to <span data-x="concept-event-fire">fire an event</span> named <code
35095+
data-x="event-media-loadedmetadata">loadedmetadata</code> at the element.</p>
3508035096

3508135097
<p class="note">Before this task is run, as part of the <span>event loop</span> mechanism, the
3508235098
rendering will have been updated to resize the <code>video</code> element if appropriate.</p>
@@ -35171,8 +35187,9 @@ interface <dfn>MediaError</dfn> {
3517135187
<li>If the element's <span>show poster flag</span> is true, set it to false and run the
3517235188
<i data-x="time marches on">time marches on</i> steps.</li>
3517335189

35174-
<li><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
35175-
<code data-x="event-media-play">play</code> at the element.</li>
35190+
<li><span>Queue an element task</span> on the <span>media element event task source</span>
35191+
given the element to <span data-x="concept-event-fire">fire an event</span> named <code
35192+
data-x="event-media-play">play</code> at the element.</li>
3517635193

3517735194
<li><span>Notify about playing</span> for the element.</li>
3517835195

@@ -35196,8 +35213,9 @@ interface <dfn>MediaError</dfn> {
3519635213
<li>Run the <span>internal pause steps</span> and set the <span>can autoplay flag</span> to
3519735214
true.</li>
3519835215

35199-
<li><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
35200-
<code data-x="event-media-pause">pause</code> at the element.</li>
35216+
<li><span>Queue an element task</span> on the <span>media element event task source</span>
35217+
given the element to <span data-x="concept-event-fire">fire an event</span> named <code
35218+
data-x="event-media-pause">pause</code> at the element.</li>
3520135219

3520235220
</ol>
3520335221

@@ -35477,7 +35495,8 @@ interface <dfn>MediaError</dfn> {
3547735495

3547835496
<li>
3547935497

35480-
<p><span>Queue a task</span> to run these steps:</p>
35498+
<p><span>Queue an element task</span> on the <span>media element event task source</span> given
35499+
the <span>media element</span> and the following steps:</p>
3548135500

3548235501
<ol>
3548335502

@@ -35609,7 +35628,8 @@ interface <dfn>MediaError</dfn> {
3560935628

3561035629
<li>
3561135630

35612-
<p><span>Queue a task</span> to run these steps:</p>
35631+
<p><span>Queue an element task</span> on the <span>media element event task source</span>
35632+
give the element and the following steps:</p>
3561335633

3561435634
<ol>
3561535635

@@ -35687,8 +35707,9 @@ interface <dfn>MediaError</dfn> {
3568735707
<li><p>If the <span>show poster flag</span> is true, set the element's <span>show poster
3568835708
flag</span> to false and run the <i data-x="time marches on">time marches on</i> steps.</p></li>
3568935709

35690-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span>
35691-
named <code data-x="event-media-play">play</code> at the element.</p></li>
35710+
<li><p><span>Queue an element task</span> on the <span>media element event task source</span>
35711+
given the element to <span data-x="concept-event-fire">fire an event</span> named <code
35712+
data-x="event-media-play">play</code> at the element.</p></li>
3569235713

3569335714
<li>
3569435715

@@ -35765,7 +35786,8 @@ interface <dfn>MediaError</dfn> {
3576535786

3576635787
<li>
3576735788

35768-
<p><span>Queue a task</span> to run these steps:</p>
35789+
<p><span>Queue an element task</span> on the <span>media element event task source</span>
35790+
given the element and the following steps:</p>
3576935791

3577035792
<ol>
3577135793

@@ -36167,8 +36189,9 @@ interface <dfn>MediaError</dfn> {
3616736189

3616836190
</li>
3616936191

36170-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
36171-
<code data-x="event-media-seeking">seeking</code> at the element.</p></li>
36192+
<li><p><span>Queue an element task</span> on the <span>media element event task source</span>
36193+
given the element to <span data-x="concept-event-fire">fire an event</span> named <code
36194+
data-x="event-media-seeking">seeking</code> at the element.</p></li>
3617236195

3617336196
<li>
3617436197

@@ -36207,12 +36230,13 @@ interface <dfn>MediaError</dfn> {
3620736230

3620836231
<li><p>&#x231B; Run the <span>time marches on</span> steps.</p></li>
3620936232

36210-
<li id="seekUpdate"><p>&#x231B; <span>Queue a task</span> to <span
36211-
data-x="concept-event-fire">fire an event</span> named <code
36212-
data-x="event-media-timeupdate">timeupdate</code> at the element.</p></li>
36233+
<li id="seekUpdate"><p>&#x231B; <span>Queue an element task</span> on the <span>media element
36234+
event task source</span> given the element to <span data-x="concept-event-fire">fire an
36235+
event</span> named <code data-x="event-media-timeupdate">timeupdate</code> at the element.</p></li>
3621336236

36214-
<li><p>&#x231B; <span>Queue a task</span> to <span data-x="concept-event-fire">fire an
36215-
event</span> named <code data-x="event-media-seeked">seeked</code> at the element.</p></li>
36237+
<li><p>&#x231B; <span>Queue an element task</span> on the <span>media element event task
36238+
source</span> given the element to <span data-x="concept-event-fire">fire an event</span> named
36239+
<code data-x="event-media-seeked">seeked</code> at the element.</p></li>
3621636240

3621736241
</ol>
3621836242

@@ -36987,7 +37011,8 @@ interface <dfn>VideoTrack</dfn> {
3698737011

3698837012
<li>
3698937013

36990-
<p><span>Queue a task</span> to run these steps:</p>
37014+
<p><span>Queue an element task</span> on the <span>media element event task source</span>
37015+
given the <span>media element</span> to run these steps:</p>
3699137016

3699237017
<ol>
3699337018

@@ -37872,7 +37897,8 @@ interface <dfn>TextTrack</dfn> : <span>EventTarget</span> {
3787237897

3787337898
<li>
3787437899

37875-
<p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
37900+
<p><span>Queue an element task</span> on the <span>media element event task source</span> given
37901+
the <span>media element</span> to <span data-x="concept-event-fire">fire an event</span> named
3787637902
<code data-x="event-media-addtrack">addtrack</code> at the <span>media element</span>'s <code
3787737903
data-x="dom-media-textTracks">textTracks</code> attribute's <code>TextTrackList</code> object,
3787837904
using <code>TrackEvent</code>, with the <code data-x="dom-TrackEvent-track">track</code>
@@ -46119,8 +46145,9 @@ interface <dfn>HTMLInputElement</dfn> : <span>HTMLElement</span> {
4611946145
"<code data-x="attr-dir-rtl">rtl</code>" if the user selected a right-to-left writing
4612046146
direction.</p></li>
4612146147

46122-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
46123-
<code data-x="event-input">input</code> at the <code>input</code> element, with the <code
46148+
<li><p><span>Queue an element task</span> on the <span>user interaction task source</span> given
46149+
the element to <span data-x="concept-event-fire">fire an event</span> named <code
46150+
data-x="event-input">input</code> at the element, with the <code
4612446151
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true.</p></li>
4612546152

4612646153
</ol>
@@ -48416,14 +48443,22 @@ ldh-str = &lt; as defined in <a href="https://tools.ietf.org/html/rfc1034#
4841648443

4841748444
<li><p>Wait for the user to have made their selection.</p></li>
4841848445

48419-
<li><p><span>Queue a task</span> to first update the element's <span
48420-
data-x="concept-input-type-file-selected">selected files</span> so that it represents the
48421-
user's selection, then <span data-x="concept-event-fire">fire an event</span> named <code
48422-
data-x="event-input">input</code> at the <code>input</code> element, with the <code
48423-
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true, and finally <span
48424-
data-x="concept-event-fire">fire an event</span> named <code
48425-
data-x="event-change">change</code> at the <code>input</code> element, with the <code
48426-
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true.</p></li>
48446+
<li>
48447+
<p><span>Queue an element task</span> on the <span>user interaction task source</span> given
48448+
the <code>input</code> element and the folllowing steps:</p>
48449+
48450+
<ol>
48451+
<li><p>Update the element's <span data-x="concept-input-type-file-selected">selected
48452+
files</span> so that it represents the user's selection.</p></li>
48453+
48454+
<li><p><span data-x="concept-event-fire">Fire an event</span> named <code
48455+
data-x="event-input">input</code> at the <code>input</code> element, with the <code
48456+
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true, and finally <span
48457+
data-x="concept-event-fire">fire an event</span> named <code
48458+
data-x="event-change">change</code> at the <code>input</code> element, with the <code
48459+
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true.</p></li>
48460+
</ol>
48461+
</li>
4842748462
</ol>
4842848463
</li>
4842948464
</ol>
@@ -51924,7 +51959,8 @@ interface <dfn>HTMLTextAreaElement</dfn> : <span>HTMLElement</span> {
5192451959
"<code data-x="attr-dir-rtl">rtl</code>" if the user selected a right-to-left writing
5192551960
direction.</p></li>
5192651961

51927-
<li><p><span>Queue a task</span> to <span data-x="concept-event-fire">fire an event</span> named
51962+
<li><p><span>Queue an element task</span> on the <span>user interaction task source</span> given
51963+
the <code>textarea</code> element to <span data-x="concept-event-fire">fire an event</span> named
5192851964
<code data-x="event-input">input</code> at the <code>textarea</code> element, with the <code
5192951965
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true.</p></li>
5193051966

@@ -57012,12 +57048,12 @@ fur
5701257048

5701357049
<li>
5701457050

57015-
<p>Let the <code>form</code>'s <span>planned navigation</span> be a new <span
57016-
data-x="concept-task">task</span> that consists of running the following steps:</p>
57051+
<p><span>Queue an element task</span> on the <span>DOM manipulation task source</span> given
57052+
the <code>form</code> element and the following steps:</p>
5701757053

5701857054
<ol>
5701957055

57020-
<li><p>Let the <code>form</code>'s <span>planned navigation</span> be null.</p></li>
57056+
<li><p>Set the <code>form</code>'s <span>planned navigation</span> to null.</p></li>
5702157057

5702257058
<li><p><span>Navigate</span><!--DONAV form--> <var>target browsing context</var> to
5702357059
<var>destination</var>. If <var>replace</var> is true, then <var>target browsing
@@ -57027,20 +57063,12 @@ fur
5702757063

5702857064
<p>For the purposes of this task, <var>target browsing context</var> and <var>replace</var> are the variables that were set up when the overall form submission
5702957065
algorithm was run, with their values as they stood when this <span>planned navigation</span>
57030-
was <span data-x="queue a task">queued</span>.</p>
57031-
57032-
</li>
57033-
57034-
<li>
57035-
57036-
<p><span data-x="queue a task">Queue the task</span> that is the <code>form</code>'s new
57037-
<span>planned navigation</span>.</p>
57038-
57039-
<p>The <span>task source</span> for this task is the <span>DOM manipulation task
57040-
source</span>.</p>
57066+
was <span data-x="queue an element task">queued</span>.</p>
5704157067

5704257068
</li>
5704357069

57070+
<li><p>Set the <code>form</code>'s <span>planned navigation</span> to the just-queued <span
57071+
data-x="concept-task">task</span>.</p>
5704457072
</ol>
5704557073

5704657074
<p>The behaviors are as follows:</p>

0 commit comments

Comments
 (0)