[html5] r8385 - [e] (0) Add an event index which acts as the definition of the event names, for [...]
whatwg at whatwg.org
whatwg at whatwg.org
Wed Jan 8 15:55:09 PST 2014
Author: ianh
Date: 2014-01-08 15:55:07 -0800 (Wed, 08 Jan 2014)
New Revision: 8385
Modified:
complete.html
index
source
Log:
[e] (0) Add an event index which acts as the definition of the event names, for editorial purposes (event names are really just strings, so they don't have, or need, a normative definition per se).
Affected topics: CSS, DOM APIs, HTML, Offline Web Applications, Security, Video Text Tracks, Video and Audio, Workers
Modified: complete.html
===================================================================
--- complete.html 2014-01-08 00:24:35 UTC (rev 8384)
+++ complete.html 2014-01-08 23:55:07 UTC (rev 8385)
@@ -638,10 +638,10 @@
<li><a href=#guidelines-for-exposing-cues-in-various-formats-as-text-track-cues><span class=secno>4.7.10.12.4 </span>Guidelines for exposing cues in various formats as text track cues</a></li>
<li><a href=#text-track-api><span class=secno>4.7.10.12.5 </span>Text track API</a></li>
<li><a href=#text-tracks-describing-chapters><span class=secno>4.7.10.12.6 </span>Text tracks describing chapters</a></li>
- <li><a href=#cue-events><span class=secno>4.7.10.12.7 </span>Event definitions</a></ol></li>
+ <li><a href=#cue-events><span class=secno>4.7.10.12.7 </span>Event handlers for objects of the text track APIs</a></ol></li>
<li><a href=#user-interface><span class=secno>4.7.10.13 </span>User interface</a></li>
<li><a href=#time-ranges><span class=secno>4.7.10.14 </span>Time ranges</a></li>
- <li><a href=#event-definitions><span class=secno>4.7.10.15 </span>Event definitions</a></li>
+ <li><a href=#the-trackevent-interface><span class=secno>4.7.10.15 </span>The <code>TrackEvent</code> interface</a></li>
<li><a href=#mediaevents><span class=secno>4.7.10.16 </span>Event summary</a></li>
<li><a href=#security-and-privacy-considerations><span class=secno>4.7.10.17 </span>Security and privacy considerations</a></li>
<li><a href=#best-practices-for-authors-using-media-elements><span class=secno>4.7.10.18 </span>Best practices for authors using media elements</a></li>
@@ -819,7 +819,7 @@
<ol>
<li><a href=#declaring-a-context-menu><span class=secno>4.11.5.1 </span>Declaring a context menu</a></li>
<li><a href=#processing-model-2><span class=secno>4.11.5.2 </span>Processing model</a></li>
- <li><a href=#event-definitions-0><span class=secno>4.11.5.3 </span>Event definitions</a></ol></li>
+ <li><a href=#the-relatedevent-interfaces><span class=secno>4.11.5.3 </span>The <code>RelatedEvent</code> interfaces</a></ol></li>
<li><a href=#commands><span class=secno>4.11.6 </span>Commands</a>
<ol>
<li><a href=#facets-0><span class=secno>4.11.6.1 </span>Facets</a></li>
@@ -980,10 +980,12 @@
<li><a href=#scroll-to-fragid><span class=secno>6.6.9 </span>Navigating to a fragment identifier</a></li>
<li><a href=#history-traversal><span class=secno>6.6.10 </span>History traversal</a>
<ol>
- <li><a href=#event-definitions-1><span class=secno>6.6.10.1 </span>Event definitions</a></ol></li>
+ <li><a href=#the-popstateevent-interface><span class=secno>6.6.10.1 </span>The <code>PopStateEvent</code> interface</a></li>
+ <li><a href=#the-hashchangeevent-interface><span class=secno>6.6.10.2 </span>The <code>HashChangeEvent</code> interface</a></li>
+ <li><a href=#the-pagetransitionevent-interface><span class=secno>6.6.10.3 </span>The <code>PageTransitionEvent</code> interface</a></ol></li>
<li><a href=#unloading-documents><span class=secno>6.6.11 </span>Unloading documents</a>
<ol>
- <li><a href=#event-definition><span class=secno>6.6.11.1 </span>Event definition</a></ol></li>
+ <li><a href=#the-beforeunloadevent-interface><span class=secno>6.6.11.1 </span>The <code>BeforeUnloadEvent</code> interface</a></ol></li>
<li><a href=#aborting-a-document-load><span class=secno>6.6.12 </span>Aborting a document load</a></ol></li>
<li><a href=#offline><span class=secno>6.7 </span>Offline Web applications</a>
<ol>
@@ -1102,7 +1104,7 @@
<li><a href=#security-risks-in-the-drag-and-drop-model><span class=secno>8.7.9 </span>Security risks in the drag-and-drop model</a></ol></ol></li>
<li><a href=#comms><span class=secno>9 </span>Communication</a>
<ol>
- <li><a href=#event-definitions-2><span class=secno>9.1 </span>Event definitions</a></li>
+ <li><a href=#the-messageevent-interfaces><span class=secno>9.1 </span>The <code>MessageEvent</code> interfaces</a></li>
<li><a href=#server-sent-events><span class=secno>9.2 </span>Server-sent events</a>
<ol>
<li><a href=#server-sent-events-intro><span class=secno>9.2.1 </span>Introduction</a></li>
@@ -1125,7 +1127,7 @@
<li><a href=#feedback-from-the-protocol><span class=secno>9.3.3 </span>Feedback from the protocol</a></li>
<li><a href=#ping-and-pong-frames><span class=secno>9.3.4 </span>Ping and Pong frames</a></li>
<li><a href=#parsing-websocket-urls><span class=secno>9.3.5 </span>Parsing WebSocket URLs</a></li>
- <li><a href=#event-definitions-3><span class=secno>9.3.6 </span>Event definitions</a></li>
+ <li><a href=#the-closeevent-interfaces><span class=secno>9.3.6 </span>The <code>CloseEvent</code> interfaces</a></li>
<li><a href=#garbage-collection-1><span class=secno>9.3.7 </span>Garbage collection</a></ol></li>
<li><a href=#web-messaging><span class=secno>9.4 </span>Cross-document messaging</a>
<ol>
@@ -1197,7 +1199,7 @@
<li><a href=#the-localstorage-attribute><span class=secno>11.2.3 </span>The <code title=dom-localStorage>localStorage</code> attribute</a></li>
<li><a href=#the-storage-event><span class=secno>11.2.4 </span>The <code title=event-storage>storage</code> event</a>
<ol>
- <li><a href=#event-definition-0><span class=secno>11.2.4.1 </span>Event definition</a></ol></li>
+ <li><a href=#the-storageevent-interface><span class=secno>11.2.4.1 </span>The <code>StorageEvent</code> interface</a></ol></li>
<li><a href=#threads><span class=secno>11.2.5 </span>Threads</a></ol></li>
<li><a href=#disk-space-0><span class=secno>11.3 </span>Disk space</a></li>
<li><a href=#privacy><span class=secno>11.4 </span>Privacy</a>
@@ -1448,7 +1450,8 @@
<li><a href=#element-content-categories class=no-num>Element content categories</a></li>
<li><a href=#attributes-1 class=no-num>Attributes</a></li>
<li><a href=#element-interfaces class=no-num>Element Interfaces</a></li>
- <li><a href=#all-interfaces class=no-num>All Interfaces</a></ol></li>
+ <li><a href=#all-interfaces class=no-num>All Interfaces</a></li>
+ <li><a href=#events-0 class=no-num>Events</a></ol></li>
<li><a href=#references class=no-num>References</a></li>
<li><a href=#acknowledgments class=no-num>Acknowledgments</a></ol>
<!--end-toc-->
@@ -2278,11 +2281,11 @@
<div class=example>
- <p>One way this could manifest itself is with <code><a href=#the-img-element>img</a></code> elements and the <code title=event-load>load</code> event. The event could fire as soon as the element has been
+ <p>One way this could manifest itself is with <code><a href=#the-img-element>img</a></code> elements and the <code title=event-load><a href=#event-load>load</a></code> event. The event could fire as soon as the element has been
parsed, especially if the image has already been cached (which is common).</p>
<p>Here, the author uses the <code title=handler-onload><a href=#handler-onload>onload</a></code> handler on an
- <code><a href=#the-img-element>img</a></code> element to catch the <code title=event-load>load</code> event:</p>
+ <code><a href=#the-img-element>img</a></code> element to catch the <code title=event-load><a href=#event-load>load</a></code> event:</p>
<pre><img src="games.png" alt="Games" onload="gamesLogoHasLoaded(event)"></pre>
@@ -2298,7 +2301,7 @@
</script></pre>
<p>However, if the author first created the <code><a href=#the-img-element>img</a></code> element and then in a separate
- script added the event listeners, there's a chance that the <code title=event-load>load</code>
+ script added the event listeners, there's a chance that the <code title=event-load><a href=#event-load>load</a></code>
event would be fired in between, leading it to be missed:</p>
<pre class=bad><!-- Do not use this style, it has a race condition! -->
@@ -3786,8 +3789,21 @@
<li>The <dfn id=uievent><code>UIEvent</code></dfn> interface's <dfn id=dom-uievent-detail title=dom-UIEvent-detail><code>detail</code></dfn> attribute</li>
<li><dfn id=event-click title=event-click><code>click</code></dfn> event</li>
+ <li><dfn id=event-dblclick title=event-dblclick><code>dblclick</code></dfn> event</li>
+ <li><dfn id=event-mousedown title=event-mousedown><code>mousedown</code></dfn> event</li>
+ <li><dfn id=event-mouseenter title=event-mouseenter><code>mouseenter</code></dfn> event</li>
+ <li><dfn id=event-mouseleave title=event-mouseleave><code>mouseleave</code></dfn> event</li>
+ <li><dfn id=event-mousemove title=event-mousemove><code>mousemove</code></dfn> event</li>
+ <li><dfn id=event-mouseout title=event-mouseout><code>mouseout</code></dfn> event</li>
+ <li><dfn id=event-mouseover title=event-mouseover><code>mouseover</code></dfn> event</li>
+ <li><dfn id=event-mouseup title=event-mouseup><code>mouseup</code></dfn> event</li>
+ <li><dfn id=event-mousewheel title=event-mousewheel><code>mousewheel</code></dfn> event</li>
- </ul><p>This specification sometimes uses the term <dfn title="">name</dfn> to refer to the event's <code title=dom-event-type>type</code>; as in, "an event named <code title="">click</code>" or "if the event name is <code title="">keypress</code>". The terms "name" and "type" for events
+ <li><dfn id=event-keydown title=event-keydown><code>keydown</code></dfn> event</li>
+ <li><dfn id=event-keyup title=event-keyup><code>keyup</code></dfn> event</li>
+ <li><dfn id=event-keypress title=event-keypress><code>keypress</code></dfn> event</li>
+
+ </ul><!--CLEANUP--><p>This specification sometimes uses the term <dfn title="">name</dfn> to refer to the event's <code title=dom-event-type>type</code>; as in, "an event named <code title="">click</code>" or "if the event name is <code title="">keypress</code>". The terms "name" and "type" for events
are synonymous.</p>
<p>The following features are defined in the DOM Parsing and
@@ -3918,6 +3934,8 @@
described in the CSS <cite>Fonts</cite> and <cite>Font Load Events</cite> specifications, including in particular
<dfn id=fontloader><code>FontLoader</code></dfn>. <a href=#refsCSSFONTS>[CSSFONTS]</a> <a href=#refsCSSFONTLOAD>[CSSFONTLOAD]</a></p>
+ <p>Some CSS specification will one day probably specify the <dfn id=event-resize title=event-resize><code>resize</code></dfn> and <dfn id=event-scroll title=event-scroll><code>scroll</code></dfn> events.</p>
+
</dd>
@@ -8718,11 +8736,12 @@
</dl><div class=impl>
+<!--CLEANUP-->
<p>Each document has a <dfn id=current-document-readiness>current document readiness</dfn>. When a <code><a href=#document>Document</a></code> object
is created, it must have its <a href=#current-document-readiness>current document readiness</a> set to the string "<code title="">loading</code>" if the document is associated with an <a href=#html-parser>HTML parser</a>, an
<a href=#xml-parser>XML parser</a>, or an XSLT processor, and to the string "<code title="">complete</code>"
otherwise. Various algorithms during page loading affect this value. When the value is set, the
- user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-readystatechange title=event-readystatechange><code>readystatechange</code></dfn> at the <code><a href=#document>Document</a></code>
+ user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-readystatechange><a href=#event-readystatechange>readystatechange</a></code> at the <code><a href=#document>Document</a></code>
object.</p>
<p>A <code><a href=#document>Document</a></code> is said to have an <dfn id=active-parser>active parser</dfn> if it is associated with an
@@ -9236,7 +9255,7 @@
nodes and drop the parsed ones, while Firefox would basically abort instead, failing to fire
the 'load' event -->
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load>load</code> at <var title="">document</var>.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at <var title="">document</var>.</li>
</ol></li>
<!--SYNCLOAD
@@ -12624,11 +12643,11 @@
<!-- the next few paragraph are similar to text in the <style> section -->
<p>Once the attempts to obtain the resource and its <a href=#critical-subresources>critical subresources</a> are
complete, the user agent must, if the loads were successful, <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-link-element>link</a></code> element, or, if the resource or one of its <a href=#critical-subresources>critical subresources</a>
failed to completely load for any reason (e.g. DNS error, HTTP 404 response, a connection being
prematurely closed, unsupported Content-Type), <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-link-element>link</a></code> element.
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-link-element>link</a></code> element.
Non-network errors in processing the resource or its subresources (e.g. CSS parse errors, PNG
decoding errors) are not failures for the purposes of this paragraph.</p>
@@ -13874,10 +13893,10 @@
<p>Once the attempts to obtain the style sheet's <a href=#critical-subresources>critical subresources</a>, if any, are
complete, or, if the style sheet has no <a href=#critical-subresources>critical subresources</a>, once the style sheet
has been parsed and processed, the user agent must, if the loads were successful or there were
- none, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-style-element>style</a></code> element, or, if one of the style sheet's
+ none, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-style-element>style</a></code> element, or, if one of the style sheet's
<a href=#critical-subresources>critical subresources</a> failed to completely load for any reason (e.g. DNS error, HTTP
404 response, a connection being prematurely closed, unsupported Content-Type), <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at
the <code><a href=#the-style-element>style</a></code> element. Non-network errors in processing the style sheet or its
subresources (e.g. CSS parse errors, PNG decoding errors) are not failures for the purposes of
this paragraph.</p>
@@ -14127,7 +14146,7 @@
<a href=#event-handlers>event handlers</a> with the same names normally supported by <a href=#html-elements>HTML
elements</a>.</p>
- <p class=example>Thus, for example, a bubbling <code title=event-error>error</code> event
+ <p class=example>Thus, for example, a bubbling <code title=event-error><a href=#event-error>error</a></code> event
dispatched on a child of <a href=#the-body-element-0>the body element</a> of a <code><a href=#document>Document</a></code> would first
trigger the <code title=handler-onerror><a href=#handler-onerror>onerror</a></code> <a href=#event-handler-content-attributes>event handler content
attributes</a> of that element, then that of the root <code><a href=#the-html-element>html</a></code> element, and only
@@ -20994,7 +21013,7 @@
<li><p>If the <a href=#list-of-available-images>list of available images</a> contains an entry for <var title="">key</var>, then set the <code><a href=#the-img-element>img</a></code> element to the <a href=#img-all title=img-all>completely
available</a> state, update the presentation of the image appropriately, <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-img-element>img</a></code> element, and abort these steps.</li>
</ol></li>
@@ -21019,14 +21038,14 @@
<li>
<p>⌛ If <var title="">selected source</var> is null, then set the element to the <a href=#img-error title=img-error>broken</a> state, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-img-element>img</a></code> element, and
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-img-element>img</a></code> element, and
abort these steps.</p>
</li>
<li>
- <p>⌛ <a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-progress-event>fire a progress event</a> named <code title=event-loadstart>loadstart</code> at
+ <p>⌛ <a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-progress-event>fire a progress event</a> named <code title=event-loadstart><a href=#event-loadstart>loadstart</a></code> at
the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21057,7 +21076,7 @@
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>, each <a href=#concept-task title=concept-task>task</a>
that is <a href=#queue-a-task title="queue a task">queued</a> by the <a href=#networking-task-source>networking task source</a>
while the image is being <a href=#fetch title=fetch>fetched</a> must <a href=#fire-a-progress-event>fire a progress
- event</a> named <code title=event-progress>progress</code> at the <code><a href=#the-img-element>img</a></code>
+ event</a> named <code title=event-progress><a href=#event-progress>progress</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
</li>
@@ -21080,10 +21099,10 @@
task">queued</a> by the <a href=#networking-task-source>networking task source</a> while the image is being <a href=#fetch title=fetch>fetched</a> must update the presentation of the image, but as each new body
part comes in, it must replace the previous image. Once one body part has been completely
decoded, the user agent must set the <code><a href=#the-img-element>img</a></code> element to the <a href=#img-all title=img-all>completely available</a> state and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code>
+ a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
- <p class=note>The <code title=event-progress>progress</code> and <code title=event-loadend>loadend</code> events are not fired for
+ <p class=note>The <code title=event-progress><a href=#event-progress>progress</a></code> and <code title=event-loadend><a href=#event-loadend>loadend</a></code> events are not fired for
<code><a href=#multipart/x-mixed-replace>multipart/x-mixed-replace</a></code> image streams.</p>
</dd>
@@ -21117,20 +21136,20 @@
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21148,20 +21167,20 @@
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21176,8 +21195,8 @@
<p>Either the image data is corrupted in some fatal way such that the image dimensions cannot
be obtained, or the image data is not in a supported file format; the user agent must set the
<code><a href=#the-img-element>img</a></code> element to the <a href=#img-error title=img-error>broken</a> state, abort the <a href=#fetch title=fetch>fetching</a> algorithm, discarding any pending <a href=#concept-task title=concept-task>tasks</a> generated by that algorithm, and then <a href=#queue-a-task>queue a
- task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <code><a href=#the-img-element>img</a></code> element and then <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-loadend>loadend</code> at the <code><a href=#the-img-element>img</a></code>
+ task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-img-element>img</a></code> element and then <a href=#fire-a-simple-event>fire a simple
+ event</a> named <code title=event-loadend><a href=#event-loadend>loadend</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
</dd>
@@ -22903,7 +22922,7 @@
from a document</a>, the user agent must <a href=#a-browsing-context-is-discarded title="a browsing context is
discarded">discard</a> the <a href=#nested-browsing-context>nested browsing context</a>.</p>
- <p class=note>This happens without any <code title=event-unload>unload</code> events firing
+ <p class=note>This happens without any <code title=event-unload><a href=#event-unload>unload</a></code> events firing
(the <a href=#nested-browsing-context>nested browsing context</a> and its <code><a href=#document>Document</a></code> are <em title="a browsing
context is discarded"><a href=#a-browsing-context-is-discarded>discarded</a></em>, not <em title="unload a document"><a href=#unload-a-document>unloaded</a></em>).</p>
@@ -22999,7 +23018,7 @@
<p>When a <code><a href=#document>Document</a></code> in an <code><a href=#the-iframe-element>iframe</a></code> is marked as <a href=#completely-loaded>completely
loaded</a>, the user agent must synchronously run the <a href=#iframe-load-event-steps>iframe load event steps</a>.</p>
- <p class=note>A <code title=event-load>load</code> event is also fired at the
+ <p class=note>A <code title=event-load><a href=#event-load>load</a></code> event is also fired at the
<code><a href=#the-iframe-element>iframe</a></code> element when it is created if no other data is loaded in it.</p>
<p>Each <code><a href=#document>Document</a></code> has an <dfn id=iframe-load-in-progress>iframe load in progress</dfn> flag and a <dfn id=mute-iframe-load>mute
@@ -23017,7 +23036,7 @@
<li><p>Set <var title="">child document</var>'s <a href=#iframe-load-in-progress>iframe load in progress</a>
flag.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load>load</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-iframe-element>iframe</a></code> element.</li>
<li><p>Unset <var title="">child document</var>'s <a href=#iframe-load-in-progress>iframe load in progress</a>
@@ -23034,7 +23053,7 @@
<a href=#browsing-context>browsing context</a> is in the <a href=#delaying-load-events-mode>delaying <code title=event-load>load</code> events
mode</a>, the <code><a href=#the-iframe-element>iframe</a></code> must <a href=#delay-the-load-event>delay the load event</a> of its document.</p>
- <p class=note>If, during the handling of the <code title=event-load>load</code> event, the
+ <p class=note>If, during the handling of the <code title=event-load><a href=#event-load>load</a></code> event, the
<a href=#browsing-context>browsing context</a> in the <code><a href=#the-iframe-element>iframe</a></code> is again <a href=#navigate title=navigate>navigated</a>, that will further <a href=#delay-the-load-event>delay the load event</a>.</p>
</div>
@@ -23611,7 +23630,7 @@
</li>
<li><p>Once the resource or plugin hass completely loaded, <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
element.</li>
</ol><p>Whether the resource is fetched successfully or not (e.g. whether the response code was a
@@ -23641,7 +23660,7 @@
element now represents this <a href=#plugin>plugin</a> instance.</p>
<p>Once the plugin is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the element.</p>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</p>
</dd>
@@ -23937,7 +23956,7 @@
<li><p><a href=#resolve-a-url title="resolve a url">Resolve</a> the <a href=#url>URL</a> specified by the <code title=attr-object-data><a href=#attr-object-data>data</a></code> attribute, relative to the element.</li>
- <li><p>If that failed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the element, then jump to the step below labeled
+ <li><p>If that failed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, then jump to the step below labeled
<i>fallback</i>.</li>
<li>
@@ -23967,7 +23986,7 @@
been obtained to begin processing the resource.</li>
<li><p>If the load failed (e.g. there was an HTTP 404 error, there was a DNS error), <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at the element, then jump to
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, then jump to
the step below labeled <i>fallback</i>.</li>
<li id=object-type-detection>
@@ -24234,7 +24253,7 @@
<p>If the <a href=#url>URL</a> of the given resource <em>is</em> <code><a href=#about:blank>about:blank</a></code>, then,
instead, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-object-element>object</a></code> element. <span class=note>No <code title=event-load>load</code> event is fired at the
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-object-element>object</a></code> element. <span class=note>No <code title=event-load><a href=#event-load>load</a></code> event is fired at the
<code><a href=#about:blank>about:blank</a></code> document itself.</span></p>
<p>The <code><a href=#the-object-element>object</a></code> element <a href=#represents>represents</a> the <a href=#nested-browsing-context>nested browsing
@@ -24295,7 +24314,7 @@
<!--CLEANUP-->
<p>Abort these steps. Once the resource is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the element.</p>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</p>
</li>
@@ -24306,7 +24325,7 @@
aren't being sandboxed</a> or the <a href=#plugin>plugin</a> can be <a href=#concept-plugin-secure title=concept-plugin-secure>secured</a>, then that <a href=#plugin>plugin</a> <a href=#object-plugin>should be used</a>. If these conditions cannot be met, or if the
<a href=#plugin>plugin</a> reports an error, jump to the step below labeled <i>fallback</i>. Otherwise
abort these steps; once the plugin is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-load>load</code> at the element.</li>
+ a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</li>
<li><p><i>Fallback</i>: The <code><a href=#the-object-element>object</a></code> element <a href=#represents>represents</a> the element's
children, ignoring any leading <code><a href=#the-param-element>param</a></code> element children. This is the element's
@@ -25142,7 +25161,7 @@
<div class=example>
<p>If the author isn't sure if user agents will all be able to render the media resources
- provided, the author can listen to the <code title=event-error>error</code> event on the last
+ provided, the author can listen to the <code title=event-error><a href=#event-error>error</a></code> event on the last
<code><a href=#the-source-element>source</a></code> element and trigger fallback behavior:</p>
<pre><script>
@@ -26066,7 +26085,7 @@
then the load failed.</li>
<li><p><i title="">Failed with elements</i>: <a href=#queue-a-task>Queue a task</a>, using the <a href=#dom-manipulation-task-source>DOM
- manipulation task source</a>, to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <var title="">candidate</var> element.</li>
+ manipulation task source</a>, to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <var title="">candidate</var> element.</li>
<li><p>Asynchronously <a href=#await-a-stable-state>await a stable state</a>. The <a href=#synchronous-section>synchronous section</a>
consists of all the remaining steps of this algorithm until the algorithm says the
@@ -26398,7 +26417,7 @@
<p class=note>A user agent that is attempting to reduce network usage while still fetching
the metadata for each <a href=#media-resource>media resource</a> would also stop buffering at this point,
following <a href=#resourceSuspend>the rules described previously</a>, which involve the
- <code title=dom-media-networkState><a href=#dom-media-networkstate>networkState</a></code> attribute switching to the <code title=dom-media-NETWORK_IDLE><a href=#dom-media-network_idle>NETWORK_IDLE</a></code> value and a <code title=event-suspend>suspend</code> event firing.</p>
+ <code title=dom-media-networkState><a href=#dom-media-networkstate>networkState</a></code> attribute switching to the <code title=dom-media-NETWORK_IDLE><a href=#dom-media-network_idle>NETWORK_IDLE</a></code> value and a <code title=event-media-suspend><a href=#event-media-suspend>suspend</a></code> event firing.</p>
<p class=note>The user agent is <em>required</em> to determine the duration of the
<a href=#media-resource>media resource</a> and go through this step before playing.</p> <!-- actually defined
@@ -27637,16 +27656,16 @@
</ol></li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">missed
- cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-enter>enter</code> for the
+ cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-media-enter><a href=#event-media-enter>enter</a></code> for the
<code><a href=#texttrackcue>TextTrackCue</a></code> object with the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">other
- cues</var> that either has its <a href=#text-track-cue-active-flag>text track cue active flag</a> set or is in <var title="">missed cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-exit>exit</code> for the <code><a href=#texttrackcue>TextTrackCue</a></code> object with the later of the
+ cues</var> that either has its <a href=#text-track-cue-active-flag>text track cue active flag</a> set or is in <var title="">missed cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-media-exit><a href=#event-media-exit>exit</a></code> for the <code><a href=#texttrackcue>TextTrackCue</a></code> object with the later of the
<a href=#text-track-cue-end-time>text track cue end time</a> and the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">current
cues</var> that does not have its <a href=#text-track-cue-active-flag>text track cue active flag</a> set, <a href=#prepare-an-event>prepare an
- event</a> named <code title=event-enter>enter</code> for the <code><a href=#texttrackcue>TextTrackCue</a></code>
+ event</a> named <code title=event-media-enter><a href=#event-media-enter>enter</a></code> for the <code><a href=#texttrackcue>TextTrackCue</a></code>
object with the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li>
@@ -27659,8 +27678,8 @@
cue">text track cues</a> associated with these <a href=#concept-task title=concept-task>tasks</a>.</p>
<p>Finally, sort <a href=#concept-task title=concept-task>tasks</a> in <var title="">events</var> that have
- the same time and same <a href=#text-track-cue-order>text track cue order</a> by placing <a href=#concept-task title=concept-task>tasks</a> that fire <code title=event-enter>enter</code> events before
- those that fire <code title=event-exit>exit</code> events.</p>
+ the same time and same <a href=#text-track-cue-order>text track cue order</a> by placing <a href=#concept-task title=concept-task>tasks</a> that fire <code title=event-media-enter><a href=#event-media-enter>enter</a></code> events before
+ those that fire <code title=event-media-exit><a href=#event-media-exit>exit</a></code> events.</p>
</li>
@@ -27672,9 +27691,9 @@
tracks</a>, and remove duplicates.</p>
<li><p>For each <a href=#text-track>text track</a> in <var title="">affected tracks</var>, in the list
- order, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-cuechange>cuechange</code> at the <code><a href=#texttrack>TextTrack</a></code> object, and, if the
+ order, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> at the <code><a href=#texttrack>TextTrack</a></code> object, and, if the
<a href=#text-track>text track</a> has a corresponding <code><a href=#the-track-element>track</a></code> element, to then <a href=#fire-a-simple-event>fire a
- simple event</a> named <code title=event-cuechange>cuechange</code> at the
+ simple event</a> named <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> at the
<code><a href=#the-track-element>track</a></code> element as well.</li>
<li><p>Set the <a href=#text-track-cue-active-flag>text track cue active flag</a> of all the <a href=#text-track-cue title="text track
@@ -29792,7 +29811,7 @@
<ol><li><p><a href=#queue-a-task>Queue a task</a> to first change the <a href=#text-track-readiness-state>text track readiness state</a> to
<a href=#text-track-failed-to-load title="text track failed to load">failed to load</a> and then <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-track-element>track</a></code>
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-track-element>track</a></code>
element.</li>
<li><p>Wait until the <a href=#text-track-readiness-state>text track readiness state</a> is no longer set to <a href=#text-track-loading title="text track loading">loading</a>.</li>
@@ -29812,11 +29831,11 @@
<li>
- <p>If the file was successfully processed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-track-element>track</a></code> element.</p>
+ <p>If the file was successfully processed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-track-element>track</a></code> element.</p>
<p>Otherwise, the file was not successfully processed (e.g. the format in question is an XML
format and the file contained a well-formedness error that the XML specification requires be
- detected and reported to the application); <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <code><a href=#the-track-element>track</a></code> element.</p>
+ detected and reported to the application); <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-track-element>track</a></code> element.</p>
</li>
@@ -30536,7 +30555,7 @@
<div class=impl>
- <h6 id=cue-events><span class=secno>4.7.10.12.7 </span>Event definitions</h6>
+ <h6 id=cue-events><span class=secno>4.7.10.12.7 </span>Event handlers for objects of the text track APIs</h6>
<p>The following are the <a href=#event-handlers>event handlers</a> that (and their corresponding <a href=#event-handler-event-type title="event handler event type">event handler event types</a>) must be supported, as <a href=#event-handler-idl-attributes>event handler IDL
attributes</a>, by all objects implementing the <code><a href=#texttracklist>TextTrackList</a></code> interface:</p>
@@ -30549,13 +30568,13 @@
attributes</a>, by all objects implementing the <code><a href=#texttrack>TextTrack</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-texttrack-oncuechange title=handler-TextTrack-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-cuechange>cuechange</code>
+ <tbody><tr><td><dfn id=handler-texttrack-oncuechange title=handler-TextTrack-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code>
</table><p>The following are the <a href=#event-handlers>event handlers</a> that (and their corresponding <a href=#event-handler-event-type title="event handler event type">event handler event types</a>) must be supported, as <a href=#event-handler-idl-attributes>event handler IDL
attributes</a>, by all objects implementing the <code><a href=#texttrackcue>TextTrackCue</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-texttrackcue-onenter title=handler-TextTrackCue-onenter><code>onenter</code></dfn> <td> <code title=event-enter>enter</code>
- <tr><td><dfn id=handler-texttrackcue-onexit title=handler-TextTrackCue-onexit><code>onexit</code></dfn> <td> <code title=event-exit>exit</code>
+ <tbody><tr><td><dfn id=handler-texttrackcue-onenter title=handler-TextTrackCue-onenter><code>onenter</code></dfn> <td> <code title=event-media-enter><a href=#event-media-enter>enter</a></code>
+ <tr><td><dfn id=handler-texttrackcue-onexit title=handler-TextTrackCue-onexit><code>onexit</code></dfn> <td> <code title=event-media-exit><a href=#event-media-exit>exit</a></code>
</table></div>
@@ -30594,7 +30613,7 @@
<p>If the user agent <a href=#expose-a-user-interface-to-the-user title="expose a user interface to the user">exposes a user interface to
the user</a> by displaying controls over the <a href=#media-element>media element</a>, then the user agent
should suppress any user interaction events while the user agent is interacting with this
- interface. (For example, if the user clicks on a video's playback control, <code title=event-mousedown>mousedown</code> events and so forth would not simultaneously be fired at
+ interface. (For example, if the user clicks on a video's playback control, <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> events and so forth would not simultaneously be fired at
elements on the page.)</p>
<p>Where possible (specifically, for starting, stopping, pausing, and unpausing playback, for
@@ -30860,7 +30879,7 @@
</div>
- <h5 id=event-definitions><span class=secno>4.7.10.15 </span>Event definitions</h5>
+ <h5 id=the-trackevent-interface><span class=secno>4.7.10.15 </span>The <code><a href=#trackevent>TrackEvent</a></code> interface</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#trackeventinit>TrackEventInit</a> eventInitDict)]
interface <dfn id=trackevent>TrackEvent</dfn> : <a href=#event>Event</a> {
@@ -31167,24 +31186,18 @@
<td>The <code><a href=#mediacontroller>MediaController</a></code> is no longer a <a href=#blocked-media-controller>blocked media controller</a>.
- <tr><td><dfn id=event-mediacontroller-ended title=event-MediaController-ended><code>ended</code></dfn>
-
- <td><code><a href=#event>Event</a></code>
-
- <td>The <code><a href=#mediacontroller>MediaController</a></code> has reached the end of all the <a href=#slaved-media-elements>slaved media
- elements</a>.
-
<tr><td><dfn id=event-mediacontroller-waiting title=event-MediaController-waiting><code>waiting</code></dfn>
<td><code><a href=#event>Event</a></code>
<td>The <code><a href=#mediacontroller>MediaController</a></code> is now a <a href=#blocked-media-controller>blocked media controller</a>.
- <tr><td><dfn id=event-mediacontcoller-ended title=event-MediaContcoller-ended><code>ended</code></dfn>
+ <tr><td><dfn id=event-mediacontroller-ended title=event-MediaController-ended><code>ended</code></dfn>
<td><code><a href=#event>Event</a></code>
- <td>All the <a href=#slaved-media-elements>slaved media elements</a> have newly <a href=#ended-playback>ended playback</a>.
+ <td>All the <a href=#slaved-media-elements>slaved media elements</a> have newly <a href=#ended-playback>ended playback</a>; the
+ <code><a href=#mediacontroller>MediaController</a></code> has reached the end of all the <a href=#slaved-media-elements>slaved media elements</a>.
<tbody><tr><td><dfn id=event-mediacontroller-durationchange title=event-MediaController-durationchange><code>durationchange</code></dfn>
@@ -31238,7 +31251,7 @@
<td><code><a href=#event>Event</a></code>
- <td>One or more tracks in the track list has been enabled or disabled.
+ <td>One or more tracks in the track list have been enabled or disabled.
<tr><td><dfn id=event-media-addtrack title=event-media-addtrack><code>addtrack</code></dfn>
@@ -31252,6 +31265,40 @@
<td>A track has been removed from the track list.
+ </table><p>The following event fires on <code><a href=#texttrack>TextTrack</a></code> objects and <code><a href=#the-track-element>track</a></code> elements:</p>
+
+ <table><thead><tr><th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody><tr><td><dfn id=event-media-cuechange title=event-media-cuechange><code>cuechange</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>One or more cues in the track have become active or stopped being active.
+
+ </table><p>The following events fire on <code><a href=#texttrackcue>TextTrackCue</a></code> objects:</p>
+
+ <table><thead><tr><th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody><tr><td><dfn id=event-media-enter title=event-media-enter><code>enter</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>The cure has become active.
+
+ <tr><td><dfn id=event-media-exit title=event-media-exit><code>exit</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>The cure has stopped being active.
+
</table><!--ADD-TOPIC:Security--><div class=impl>
<h5 id=security-and-privacy-considerations><span class=secno>4.7.10.17 </span>Security and privacy considerations</h5>
@@ -35891,7 +35938,7 @@
<li><p>Set <var title="">table</var>'s <a href=#currently-sorting-flag>currently-sorting flag</a> to true.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-sort>sort</code> that is
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-sort><a href=#event-sort>sort</a></code> that is
cancelable at <var title="">table</var>.</li>
<li><p>If the event fired in the previous step was canceled, then jump to the step labeled
@@ -35904,7 +35951,7 @@
<p class=note>Even if <var title="">table</var> was a <a href=#sorting-enabled-table-element>sorting-enabled <code>table</code>
element</a> when the algorithm was invoked, the DOM might have been entirely changed by the
- event handlers for the <code title=event-sort>sort</code> event, so this has to be verified at
+ event handlers for the <code title=event-sort><a href=#event-sort>sort</a></code> event, so this has to be verified at
this stage, not earlier.</p>
</li>
@@ -37463,7 +37510,7 @@
<p><button>Submit order</button></p>
</form></pre>
- <p class=note>When a form is submitted, <code title=event-invalid>invalid</code> events are
+ <p class=note>When a form is submitted, <code title=event-invalid><a href=#event-invalid>invalid</a></code> events are
fired at each form control that is invalid, and then at the <code><a href=#the-form-element>form</a></code> element itself. This
can be useful for displaying a summary of the problems with the form, since typically the browser
itself will only report one problem at a time.</p>
@@ -39818,7 +39865,7 @@
"<code title=attr-dir-rtl><a href=#attr-dir-rtl>rtl</a></code>" if the user selected a right-to-left writing
direction.</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element.</li>
</ol></div>
@@ -41873,7 +41920,7 @@
activation steps</a> consist of setting the <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a>
and the element's <code title=dom-input-indeterminate><a href=#dom-input-indeterminate>indeterminate</a></code> IDL attribute back to
the values they had before the <a href=#pre-click-activation-steps>pre-click activation steps</a> were run. The
- <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. --></p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42002,7 +42049,7 @@
</ul><!--CLEANUP--><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, then: The <a href=#pre-click-activation-steps>pre-click
activation steps</a> consist of setting the element's <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a> to true. The <a href=#canceled-activation-steps>canceled activation steps</a>
consist of setting the element's <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a> to false. The
- <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. -->.</p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42119,18 +42166,19 @@
<li><p>Wait for the user to have made their selection.</li>
+<!--CLEANUP-->
<li><p><a href=#queue-a-task>Queue a task</a> to first update the element's <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> so that it represents the user's
- selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire a
- simple event</a> that bubbles named <code title=event-change>change</code> at the
+ selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire a
+ simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</li>
- </ol><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, the user agent should allow the
+ </ol><!--CLEANUP--><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, the user agent should allow the
user to change the files on the list in other ways also, e.g. adding or removing files by
drag-and-drop. When the user does so, the user agent must <a href=#queue-a-task>queue a task</a> to first
update the element's <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> so that
it represents the user's new selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire
- a simple event</a> that bubbles named <code title=event-change>change</code> at the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire
+ a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42473,10 +42521,10 @@
<p>The <a href=#concept-task title=concept-task>task</a> that is <a href=#queue-a-task title="queue a task">queued</a> by
the <a href=#networking-task-source>networking task source</a> once the resource has been <a href=#fetch title=fetch>fetched</a>, must, if the download was successful and the image is <i title=input-img-available><a href=#input-img-available>available</a></i>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the <code><a href=#the-input-element>input</a></code> element; and
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-input-element>input</a></code> element; and
otherwise, if the fetching process fails without a response from the remote server, or completes
but the image is not a valid or supported image, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> on the <code><a href=#the-input-element>input</a></code> element.</p>
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> on the <code><a href=#the-input-element>input</a></code> element.</p>
<hr></div>
@@ -43767,13 +43815,13 @@
<h5 id=common-input-element-events><span class=secno>4.10.5.5 </span>Common event behaviors</h5>
- <p>When the <code title=event-input>input</code> and <code title=event-change>change</code>
+ <p>When the <code title=event-input-input><a href=#event-input-input>input</a></code> and <code title=event-input-change><a href=#event-input-change>change</a></code>
events <a href=#concept-input-apply title=concept-input-apply>apply</a> (which is the case for all
<code><a href=#the-input-element>input</a></code> controls other than <a href=#concept-button title=concept-button>buttons</a> and those with
the <code title=attr-input-type><a href=#attr-input-type>type</a></code> attribute in the <a href="#hidden-state-(type=hidden)" title=attr-input-type-hidden>Hidden</a> state), the events are fired to indicate that the
user has interacted with the control. The <dfn id=event-input-input title=event-input-input><code>input</code></dfn>
event fires whenever the user has modified the data of the control. The <dfn id=event-input-change title=event-input-change><code>change</code></dfn> event fires when the value is committed, if
- that makes sense for the control, or else when the control loses focus. In all cases, the <code title=event-input>input</code> event comes before the corresponding <code title=event-change>change</code> event (if any).</p>
+ that makes sense for the control, or else when the control loses focus. In all cases, the <code title=event-input-input><a href=#event-input-input>input</a></code> event comes before the corresponding <code title=event-input-change><a href=#event-input-change>change</a></code> event (if any).</p>
<p>When an <code><a href=#the-input-element>input</a></code> element has a defined <a href=#activation-behavior>activation behavior</a>, the rules
for dispatching these events, if they <a href=#concept-input-apply title=concept-input-apply>apply</a>, are given
@@ -43784,15 +43832,15 @@
which these events <a href=#concept-input-apply title=concept-input-apply>apply</a>, and for which the user
interface involves both interactive manipulation and an explicit commit action, then when the user
changes the element's <a href=#concept-fe-value title=concept-fe-value>value</a>, the user agent must
- <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and any time the user commits
+ <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and any time the user commits
the change, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-change>change</code> at the <code><a href=#the-input-element>input</a></code> element.</p>
+ bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the <code><a href=#the-input-element>input</a></code> element.</p>
<p class=example>An example of a user interface involving both interactive manipulation and a
commit action would be a <a href="#range-state-(type=range)" title=attr-input-type-range>Range</a> controls that use a
slider, when manipulated using a pointing device. While the user is dragging the control's knob,
- <code title=event-input>input</code> events would fire whenever the position changed, whereas
- the <code title=event-change>change</code> event would only fire when the user let go of the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> events would fire whenever the position changed, whereas
+ the <code title=event-input-change><a href=#event-input-change>change</a></code> event would only fire when the user let go of the
knob, committing to a specific value.</p>
<p>For <code><a href=#the-input-element>input</a></code> elements without a defined <a href=#activation-behavior>activation behavior</a>, but to
@@ -43800,8 +43848,8 @@
interface involves an explicit commit action but no intermediate manipulation, then any time the
user commits a change to the element's <a href=#concept-fe-value title=concept-fe-value>value</a>, the user
agent must <a href=#queue-a-task>queue a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and then <a href=#fire-a-simple-event>fire a
- simple event</a> that bubbles named <code title=event-change>change</code> at the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and then <a href=#fire-a-simple-event>fire a
+ simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</p>
<p class=example>An example of a user interface with a commit action would be a <a href="#color-state-(type=color)" title=attr-input-type-color>Color</a> control that consists of a single button that brings
@@ -43819,8 +43867,8 @@
which these events <a href=#concept-input-apply title=concept-input-apply>apply</a>, any time the user causes the
element's <a href=#concept-fe-value title=concept-fe-value>value</a> to change without an explicit commit
action, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element. The
- corresponding <code title=event-change>change</code> event, if any, will be fired when the
+ bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element. The
+ corresponding <code title=event-input-change><a href=#event-input-change>change</a></code> event, if any, will be fired when the
control <a href=#unfocusing-steps title="unfocusing steps">loses focus</a>.</p>
<p class=example>Examples of a user changing the element's <a href=#concept-fe-value title=concept-fe-value>value</a> would include the user typing into a text field, pasting a
@@ -43833,7 +43881,7 @@
of the user changing the element's <a href=#concept-fe-value title=concept-fe-value>value</a> without a commit
step.</p>
- <p>In the case of <a href=#concept-task title=concept-task>tasks</a> that just fire an <code title=event-input>input</code> event, user agents may wait for a suitable break in the user's
+ <p>In the case of <a href=#concept-task title=concept-task>tasks</a> that just fire an <code title=event-input-input><a href=#event-input-input>input</a></code> event, user agents may wait for a suitable break in the user's
interaction before <a href=#queue-a-task title="queue a task">queuing</a> the tasks; for example, a user agent
could wait for the user to have not hit a key for 100ms, so as to only fire the event when the
user pauses, instead of continuously for each keystroke. <!-- similar text is present in the
@@ -43841,8 +43889,8 @@
<p>When the user agent is to change an <code><a href=#the-input-element>input</a></code> element's <a href=#concept-fe-value title=concept-fe-value>value</a> on behalf of the user (e.g. as part of a form prefilling
feature), the user agent must <a href=#queue-a-task>queue a task</a> to first update the <a href=#concept-fe-value title=concept-fe-value>value</a> accordingly, then <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, then
- <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at
+ bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, then
+ <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at
the <code><a href=#the-input-element>input</a></code> element.</p>
<p class=note>These events are not fired in response to changes made to the values of form
@@ -43983,7 +44031,7 @@
<li><p>Let <var title="">menu</var> be the element's <a href=#designated-pop-up-menu>designated pop-up menu</a>, if
any. If there isn't one, then abort these steps.</li>
- <li><p><a href=#concept-event-fire title=concept-event-fire>Fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show>show</code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
+ <li><p><a href=#concept-event-fire title=concept-event-fire>Fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show><a href=#event-show>show</a></code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
interface, with the <code title=dom-RelatedEvent-relatedTarget><a href=#dom-relatedevent-relatedtarget>relatedTarget</a></code> attribute
initialized to the <code><a href=#the-button-element>button</a></code> element. The event must be cancelable. <!-- v2: include
modifier key information --></li>
@@ -44226,8 +44274,8 @@
user agent must <a href=#send-select-update-notifications>send <code>select</code> update notifications</a>.</p>
<p>When the user agent is to <dfn id=send-select-update-notifications>send <code>select</code> update notifications</dfn>, <a href=#queue-a-task>queue
- a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-select-element>select</a></code> element, and then <a href=#fire-a-simple-event>fire a simple
- event</a> that bubbles named <code title=event-change>change</code> at the
+ a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-select-element>select</a></code> element, and then <a href=#fire-a-simple-event>fire a simple
+ event</a> that bubbles named <code title=event-change><a href=#event-change>change</a></code> at the
<code><a href=#the-select-element>select</a></code> element, using the <a href=#user-interaction-task-source>user interaction task source</a> as the task
source.</p>
@@ -45045,7 +45093,7 @@
<p>When a <code><a href=#the-textarea-element>textarea</a></code> is <a href=#concept-fe-mutable title=concept-fe-mutable>mutable</a>, its <a href=#concept-textarea-raw-value title=concept-textarea-raw-value>raw value</a> should be editable by the user: the user agent
should allow the user to edit, insert, and remove text, and to insert and remove line breaks in
the form of U+000A LINE FEED (LF) characters. Any time the user causes the element's <a href=#concept-textarea-raw-value title=concept-textarea-raw-value>raw value</a> to change, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-textarea-element>textarea</a></code> element. User agents may wait for a
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-textarea-element>textarea</a></code> element. User agents may wait for a
suitable break in the user's interaction before queuing the task; for example, a user agent could
wait for the user to have not hit a key for 100ms, so as to only fire the event when the user
pauses, instead of continuously for each keystroke.</p> <!-- same text is present in the <input>
@@ -45076,7 +45124,7 @@
"<code title=attr-dir-rtl><a href=#attr-dir-rtl>rtl</a></code>" if the user selected a right-to-left writing
direction.</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-textarea-element>textarea</a></code> element.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-textarea-element>textarea</a></code> element.</li>
</ol></div>
@@ -48378,7 +48426,7 @@
contents of the text field to be fully selected, with the selection direction being none, if the
platform support selections with the direction <i>none</i>, or otherwise <i>forward</i>. The user
agent must then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</p>
@@ -48429,7 +48477,7 @@
<a href=#case-sensitive>case-sensitive</a> match for the string "<code title="">backward</code>", <i>forward</i>
if <var title="">direction</var> is a <a href=#case-sensitive>case-sensitive</a> match for the string "<code title="">forward</code>" or if the platform does not support selections with the direction
<i>none</i>, and <i>none</i> otherwise (including if the argument is omitted). The user agent must
- then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</p>
@@ -48547,7 +48595,7 @@
</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</li>
</ol><p>All elements to which this API <a href=#concept-input-apply title=concept-input-apply>applies</a> have either a
@@ -48723,7 +48771,7 @@
<p>For each element <var title="">field</var> in <var title="">invalid controls</var>, if any,
in <a href=#tree-order>tree order</a>, run the following substeps:</p>
- <ol><li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-invalid>invalid</code> that
+ <ol><li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that
is cancelable at <var title="">field</var>.</li>
<li><p>If the event was not canceled, then add <var title="">field</var> to <var title="">unhandled invalid controls</var>.</li>
@@ -48874,7 +48922,7 @@
<dd>
- <p>Returns true if the element's value has no validity problems; false otherwise. Fires an <code title=event-invalid>invalid</code> event at the element in the latter case.</p>
+ <p>Returns true if the element's value has no validity problems; false otherwise. Fires an <code title=event-invalid><a href=#event-invalid>invalid</a></code> event at the element in the latter case.</p>
</dd>
@@ -48883,7 +48931,7 @@
<dd>
<p>Returns true if the element's value has no validity problems; otherwise, returns false, fires
- an <code title=event-invalid>invalid</code> event at the element, and (if the event isn't
+ an <code title=event-invalid><a href=#event-invalid>invalid</a></code> event at the element, and (if the event isn't
canceled) reports the problem to the user.</p>
</dd>
@@ -48992,13 +49040,13 @@
</dl><p>When the <dfn id=dom-cva-checkvalidity title=dom-cva-checkValidity><code>checkValidity()</code></dfn> method is
invoked, if the element is a <a href=#candidate-for-constraint-validation>candidate for constraint validation</a> and does not <a href=#concept-fv-valid title=concept-fv-valid>satisfy its constraints</a>, the user agent must <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-invalid>invalid</code> that is cancelable (but in this case
+ event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that is cancelable (but in this case
has no default action) at the element and return false. Otherwise, it must only return true
without doing anything else.</p>
<p>When the <dfn id=dom-cva-reportvalidity title=dom-cva-reportValidity><code>reportValidity()</code></dfn> method is
invoked, if the element is a <a href=#candidate-for-constraint-validation>candidate for constraint validation</a> and does not <a href=#concept-fv-valid title=concept-fv-valid>satisfy its constraints</a>, the user agent must: <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-invalid>invalid</code> that is cancelable at the element,
+ event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that is cancelable at the element,
and if that event is not canceled, report the problems with the constraints of that element to the
user; then, return false. Otherwise, it must only return true without doing anything else. When
reporting the problem with the constraints to the user, the user agent may run the <a href=#focusing-steps>focusing
@@ -49155,12 +49203,12 @@
method</var> flag is not set, and the <var title="">submitter</var> element's <a href=#concept-fs-novalidate title=concept-fs-novalidate>no-validate state</a> is false, then <a href=#interactively-validate-the-constraints>interactively
validate the constraints</a> of <var title="">form</var> and examine the result: if the result
is negative (the constraint validation concluded that there were invalid fields and probably
- informed the user of this) then <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-invalid>invalid</code> at the <var title="">form</var> element and then abort these
+ informed the user of this) then <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> at the <var title="">form</var> element and then abort these
steps.</li>
<li><p>If the <var title="">submitted from <code title=dom-form-submit><a href=#dom-form-submit>submit()</a></code>
method</var> flag is not set, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles and is
- cancelable named <code title=event-submit>submit</code>, at <var title="">form</var>. If the
+ cancelable named <code title=event-submit><a href=#event-submit>submit</a></code>, at <var title="">form</var>. If the
event's default action is prevented (i.e. if the event is canceled) then abort these steps.
Otherwise, continue (effectively the default action is to perform the submission).</li>
@@ -50042,10 +50090,10 @@
<h4 id=resetting-a-form><span class=secno>4.10.23 </span>Resetting a form</h4>
<p>When a <code><a href=#the-form-element>form</a></code> element <var title="">form</var> is <dfn id=concept-form-reset title=concept-form-reset>reset</dfn>, the user agent must <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-reset>reset</code>, that bubbles and is cancelable, at <var title="">form</var>, and then, if that event is not canceled, must invoke the <a href=#concept-form-reset-control title=concept-form-reset-control>reset algorithm</a> of each <a href=#category-reset title=category-reset>resettable element</a> whose <a href=#form-owner>form owner</a> is <var title="">form</var>.</p>
+ <code title=event-reset><a href=#event-reset>reset</a></code>, that bubbles and is cancelable, at <var title="">form</var>, and then, if that event is not canceled, must invoke the <a href=#concept-form-reset-control title=concept-form-reset-control>reset algorithm</a> of each <a href=#category-reset title=category-reset>resettable element</a> whose <a href=#form-owner>form owner</a> is <var title="">form</var>.</p>
<p>Each <a href=#category-reset title=category-reset>resettable element</a> defines its own <dfn id=concept-form-reset-control title=concept-form-reset-control>reset algorithm</dfn>. Changes made to form controls as part of
- these algorithms do not count as changes caused by the user (and thus, e.g., do not cause <code title=event-input>input</code> events to fire).</p>
+ these algorithms do not count as changes caused by the user (and thus, e.g., do not cause <code title=event-input><a href=#event-input>input</a></code> events to fire).</p>
</div>
@@ -50120,7 +50168,7 @@
</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-toggle>toggle</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-toggle><a href=#event-toggle>toggle</a></code> at the
<code><a href=#the-details-element>details</a></code> element.</li>
</ol><p>The <a href=#task-source>task source</a> for this task must be the <a href=#dom-manipulation-task-source>DOM manipulation task
@@ -50660,8 +50708,8 @@
element in the same <a href=#home-subtree>home subtree</a> whose <code title=attr-menu-type><a href=#attr-menu-type>type</a></code>
attribute is in the <a href=#popup-menu-state title="popup menu state">popup menu</a> state.</p>
- <p class=note>When a user right-clicks on an element with a <code title=attr-contextmenu><a href=#attr-contextmenu>contextmenu</a></code> attribute, the user agent will first fire a <code title=event-contextmenu>contextmenu</code> event at the element, and then, if that event is not
- canceled, a <code title=event-show>show</code> event at the <code><a href=#the-menu-element>menu</a></code> element.</p>
+ <p class=note>When a user right-clicks on an element with a <code title=attr-contextmenu><a href=#attr-contextmenu>contextmenu</a></code> attribute, the user agent will first fire a <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event at the element, and then, if that event is not
+ canceled, a <code title=event-show><a href=#event-show>show</a></code> event at the <code><a href=#the-menu-element>menu</a></code> element.</p>
<div class=example>
@@ -50702,7 +50750,7 @@
<dl class=switch><dt>If the user requested a context menu using a pointing device</dt>
- <dd><p>The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-contextmenu>contextmenu</code>, that bubbles and is cancelable, and that uses the
+ <dd><p>The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code>, that bubbles and is cancelable, and that uses the
<code><a href=#mouseevent>MouseEvent</a></code> interface, at the element for which the menu was requested. The context
information of the event must be initialized to the same values as the last
<code><a href=#mouseevent>MouseEvent</a></code> user interaction event that was fired as part of the gesture that was
@@ -50714,10 +50762,10 @@
event named <code title=event-contextmenu>contextmenu</code></a> that bubbles and is
cancelable at the element for which the menu was requested.</dd>
- </dl><p class=note>Typically, therefore, the firing of the <code title=event-contextmenu>contextmenu</code> event will be the default action of a <code title=mouseup>mouseup</code> or <code title=event-keyup>keyup</code> event. The exact sequence
+ </dl><p class=note>Typically, therefore, the firing of the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event will be the default action of a <code title=mouseup>mouseup</code> or <code title=event-keyup><a href=#event-keyup>keyup</a></code> event. The exact sequence
of events is UA-dependent, as it will vary based on platform conventions.</p>
- <p>The default action of the <code title=event-contextmenu>contextmenu</code> event depends on
+ <p>The default action of the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event depends on
whether or not the element for which the menu was requested has a non-null <a href=#assigned-context-menu>assigned context
menu</a> when the event dispatch has completed, as follows.</p>
@@ -50726,14 +50774,14 @@
one.</p>
<p>Otherwise, let <var title="">subject</var> be the element for which the menu was requested, and
- let <var title="">menu</var> be the <a href=#assigned-context-menu>assigned context menu</a> of <var title="">target</var> immediately after the <code title=event-contextmenu>contextmenu</code>
+ let <var title="">menu</var> be the <a href=#assigned-context-menu>assigned context menu</a> of <var title="">target</var> immediately after the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code>
event's dispatch has completed. The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a
- <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show>show</code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
+ <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show><a href=#event-show>show</a></code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
interface, with the <code title=dom-RelatedEvent-relatedTarget><a href=#dom-relatedevent-relatedtarget>relatedTarget</a></code> attribute
initialized to <var title="">subject</var>. The event must be cancelable. <!-- v2: include
modifier key information --></p>
- <p>If <em>this</em> event (the <code title=event-show>show</code> event) is not canceled, then
+ <p>If <em>this</em> event (the <code title=event-show><a href=#event-show>show</a></code> event) is not canceled, then
the user agent must <a href=#construct-and-show-a-menu title="construct and show a menu">construct and show</a> the menu for
<var title="">menu</var> with <var title="">subject</var> as the subject.</p>
@@ -50747,7 +50795,7 @@
<p>User agents may provide means for bypassing the context menu processing model, ensuring that
the user can always access the UA's default context menus. For example, the user agent could
handle right-clicks that have the Shift key depressed in such a way that it does not fire the
- <code title=event-contextmenu>contextmenu</code> event and instead always shows the default
+ <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event and instead always shows the default
context menu.</p>
<hr><p>The <dfn id=dom-contextmenu title=dom-contextMenu><code>contextMenu</code></dfn> IDL attribute must
@@ -50778,7 +50826,7 @@
<p><img src=http://images.whatwg.org/contextmenu-expanded.png alt="This would result in the same basic interface, but with a longer menu; the disclosure triangle having been replaced by items such as 'View Image', 'Copy Image', 'Copy Image Location', and so forth."></div>
- <h5 id=event-definitions-0><span class=secno>4.11.5.3 </span>Event definitions</h5>
+ <h5 id=the-relatedevent-interfaces><span class=secno>4.11.5.3 </span>The <code><a href=#relatedevent>RelatedEvent</a></code> interfaces</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#relatedeventinit>RelatedEventInit</a> eventInitDict)]
interface <dfn id=relatedevent>RelatedEvent</dfn> : <a href=#event>Event</a> {
@@ -50793,7 +50841,7 @@
<dd>
- <p>Returns the other event target involved in this event. For example, when a <code title=event-show>show</code> event fires on a <code><a href=#the-menu-element>menu</a></code> element, the other event
+ <p>Returns the other event target involved in this event. For example, when a <code title=event-show><a href=#event-show>show</a></code> event fires on a <code><a href=#the-menu-element>menu</a></code> element, the other event
target involved in the event would be the element for which the menu is being shown.</p>
</dd>
@@ -51588,15 +51636,15 @@
</ol></li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-close title=event-close><code>close</code></dfn> at <var title="">subject</var>.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-close><a href=#event-close>close</a></code> at <var title="">subject</var>.</li>
</ol><!--TOPIC:DOM APIs--><p>The <dfn id=dom-dialog-returnvalue title=dom-dialog-returnValue><code>returnValue</code></dfn> IDL attribute, on
getting, must return the last value to which it was set. On setting, it must be set to the new
value. When the element is created, it must be set to the empty string.</p>
<!--TOPIC:HTML-->
- <hr><p><strong>Canceling dialogs</strong>: When a <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog
- stack</a> is not empty, user agents may provide a user interface that, upon activation, <a href=#queue-a-task title="queue a task">queues a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-cancel title=event-cancel><code>cancel</code></dfn> that is cancelable at the top <code><a href=#the-dialog-element>dialog</a></code>
+ <hr><!--CLEANUP--><p><strong>Canceling dialogs</strong>: When a <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog
+ stack</a> is not empty, user agents may provide a user interface that, upon activation, <a href=#queue-a-task title="queue a task">queues a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-cancel><a href=#event-cancel>cancel</a></code> that is cancelable at the top <code><a href=#the-dialog-element>dialog</a></code>
element on the <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog stack</a>. The default action of
this event must be to check if that element has an <code title=attr-dialog-open><a href=#attr-dialog-open>open</a></code>
attribute, and if it does, <a href=#close-the-dialog>close the dialog</a> with no return value.</p>
@@ -52230,14 +52278,14 @@
<ol><li><p>Let <var title="">src</var> be the value of the element's <code title=attr-script-src><a href=#attr-script-src>src</a></code> attribute.</li>
<li><p>If <var title="">src</var> is the empty string, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at the element, and abort
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, and abort
these steps.</li>
<li><p><a href=#resolve-a-url title="resolve a url">Resolve</a> <var title="">src</var> relative to the
element.</li>
<li><p>If the previous step failed, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the element, and abort these
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, and abort these
steps.</li>
<li>
@@ -52421,7 +52469,7 @@
<dl class=switch><dt>If the load resulted in an error (for example a DNS error, or an HTTP 404 error)</dt>
<dd><p>Executing the script block must just consist of <a href=#fire-a-simple-event title="fire a simple event">firing
- a simple event</a> named <code title=event-error>error</code> at the element.</dd>
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element.</dd>
<dt>If the load was successful</dt>
@@ -52510,7 +52558,7 @@
<li>
- <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-beforescriptexecute>beforescriptexecute</code> that bubbles and is cancelable
+ <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-beforescriptexecute><a href=#event-beforescriptexecute>beforescriptexecute</a></code> that bubbles and is cancelable
at the <code><a href=#the-script-element>script</a></code> element.</p>
<p>If the event is canceled, then abort these steps.</p>
@@ -52577,17 +52625,17 @@
<li>
- <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-afterscriptexecute>afterscriptexecute</code> that bubbles (but is not
+ <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-afterscriptexecute><a href=#event-afterscriptexecute>afterscriptexecute</a></code> that bubbles (but is not
cancelable) at the <code><a href=#the-script-element>script</a></code> element.</p>
</li>
<li>
- <p>If the script is from an external file, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-script-element>script</a></code> element.</p>
+ <p>If the script is from an external file, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-script-element>script</a></code> element.</p>
<p>Otherwise, the script is internal; <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the <code><a href=#the-script-element>script</a></code>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-script-element>script</a></code>
element.</p>
</li>
@@ -55236,7 +55284,7 @@
attribute's allowed keywords correspond to alignment points in the
font:</p>
- <p><img src=http://images.whatwg.org/baselines.png width=738 alt="The top of the em square is roughly at the top of the glyphs in a font, the hanging baseline is where some glyphs like आ are anchored, the middle is half-way between the top of the em square and the bottom of the em square, the alphabetic baseline is where characters like Á, ÿ, f, and Ω are anchored, the ideographic baseline is where glyphs like 私 and 達 are anchored, and the bottom of the em square is roughly at the bottom of the glyphs in a font. The top and bottom of the bounding box can be far from these baselines, due to glyphs extending far outside the em square." height=300></p>
+ <p><img src=http://images.whatwg.org/baselines.png width=738 alt="The top of the em square is roughly at the top of the glyphs in a font, the hanging baseline is where some glyphs like आ are anchored, the middle is half-way between the top of the em square and the bottom of the em square, the alphabetic baseline is where characters like Á, ÿ, f, and Ω are anchored, the ideographic baseline is where glyphs like " height=300>79C1; and 達 are anchored, and the bottom of the em square is roughly at the bottom of the glyphs in a font. The top and bottom of the bounding box can be far from these baselines, due to glyphs extending far outside the em square."></p>
<p>The keywords map to these alignment points as follows:</p>
@@ -60084,8 +60132,8 @@
</ul><p class=example>For example, if the user is using a keyboard to push a <code><a href=#the-button-element>button</a></code>
element by pressing the space bar, the element would match this pseudo-class in between the
- time that the element received the <code title=event-keydown>keydown</code> event and the
- time the element received the <code title=event-keyup>keyup</code> event.</p>
+ time that the element received the <code title=event-keydown><a href=#event-keydown>keydown</a></code> event and the
+ time the element received the <code title=event-keyup><a href=#event-keyup>keyup</a></code> event.</p>
</li>
@@ -64713,12 +64761,12 @@
running the event listener for a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event whose
type is in the following list:</p>
- <ul class=brief><li><code title=event-change>change</code></li>
+ <ul class=brief><li><code title=event-change><a href=#event-change>change</a></code></li>
<li><code title=event-click><a href=#event-click>click</a></code></li>
- <li><code title=event-dblclick>dblclick</code></li>
- <li><code title=event-mouseup>mouseup</code></li>
- <li><code title=event-reset>reset</code></li>
- <li><code title=event-submit>submit</code></li>
+ <li><code title=event-dblclick><a href=#event-dblclick>dblclick</a></code></li>
+ <li><code title=event-mouseup><a href=#event-mouseup>mouseup</a></code></li>
+ <li><code title=event-reset><a href=#event-reset>reset</a></code></li>
+ <li><code title=event-submit><a href=#event-submit>submit</a></code></li>
</ul></li>
<li>
@@ -65164,7 +65212,7 @@
<p>If <var title="">url</var> <em>is</em> "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing
context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the selected
<a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected <a href=#browsing-context>browsing context</a>'s <a href=#concept-document-window title=concept-document-window><code>Window</code> object's <code>Document</code></a> object
(and the <code title=dom-event-currentTarget>currentTarget</code> set to the <code><a href=#window>Window</a></code>
object).</p>
@@ -66957,7 +67005,7 @@
<p>When the <dfn id=dom-location-reload title=dom-location-reload><code>reload()</code></dfn> method is invoked, the
user agent must run the appropriate steps from the following list:</p>
- <dl class=switch><dt>If the currently executing <a href=#concept-task title=concept-task>task</a> is the dispatch of a <code title=event-resize>resize</code> event in response to the user resizing the <a href=#browsing-context>browsing
+ <dl class=switch><dt>If the currently executing <a href=#concept-task title=concept-task>task</a> is the dispatch of a <code title=event-resize><a href=#event-resize>resize</a></code> event in response to the user resizing the <a href=#browsing-context>browsing
context</a></dt>
<dd><p>Repaint the <a href=#browsing-context>browsing context</a> and abort these steps.</dd> <!-- this
@@ -67825,7 +67873,7 @@
<!-- next two paragraphs are nearly identical to the navigate-text section, keep them in sync -->
<p>When no more bytes are available, the user agent must <a href=#queue-a-task>queue a task</a> for the parser
- to process the implied EOF character, which eventually causes a <code title=event-load>load</code> event to be fired.</p>
+ to process the implied EOF character, which eventually causes a <code title=event-load><a href=#event-load>load</a></code> event to be fired.</p>
<p>After creating the <code><a href=#document>Document</a></code> object, but before any script execution, certainly
before the parser <a href=#stop-parsing title="stop parsing">stops</a>, the user agent must <a href=#update-the-session-history-with-the-new-page>update the
@@ -67913,7 +67961,7 @@
navigate-plugin sections; keep them all in sync -->
<p>When no more bytes are available, the user agent must <a href=#queue-a-task>queue a task</a> for the parser
- to process the implied EOF character, which eventually causes a <code title=event-load>load</code> event to be fired.</p>
+ to process the implied EOF character, which eventually causes a <code title=event-load><a href=#event-load>load</a></code> event to be fired.</p>
<p>After creating the <code><a href=#document>Document</a></code> object, but potentially before the page has finished
parsing, the user agent must <a href=#update-the-session-history-with-the-new-page>update the session history with the new page</a>.</p>
@@ -67947,7 +67995,7 @@
resources, the user agent must act as if there were no more bytes for those resources whenever the
boundary following the body part is reached.</p>
- <p class=note>Thus, <code title=event-load>load</code> events (and for that matter <code title=event-unload>unload</code> events) do fire for each body part loaded.</p>
+ <p class=note>Thus, <code title=event-load><a href=#event-load>load</a></code> events (and for that matter <code title=event-unload><a href=#event-unload>unload</a></code> events) do fire for each body part loaded.</p>
<h4 id=read-media><span class=secno>6.6.6 </span><dfn title=navigate-media>Page load processing model for media</dfn></h4>
@@ -68347,14 +68395,11 @@
</ol><p>The <a href=#task-source>task source</a> for the tasks mentioned above is the <a href=#dom-manipulation-task-source>DOM manipulation task
source</a>.</p>
+ </div>
- <h5 id=event-definitions-1><span class=secno>6.6.10.1 </span>Event definitions</h5>
- </div>
+ <h5 id=the-popstateevent-interface><span class=secno>6.6.10.1 </span>The <code><a href=#popstateevent>PopStateEvent</a></code> interface</h5>
- <p>The <dfn id=event-popstate title=event-popstate><code>popstate</code></dfn> event is fired in certain cases
- when navigating to a <a href=#session-history-entry>session history entry</a>.</p>
-
<pre class=idl>[Constructor(DOMString type, optional <a href=#popstateeventinit>PopStateEventInit</a> eventInitDict)]
interface <dfn id=popstateevent>PopStateEvent</dfn> : <a href=#event>Event</a> {
readonly attribute any <a href=#dom-popstateevent-state title=dom-PopStateEvent-state>state</a>;
@@ -68381,10 +68426,9 @@
</div>
- <hr><p>The <dfn id=event-hashchange title=event-hashchange><code>hashchange</code></dfn> event is fired when navigating
- to a <a href=#session-history-entry>session history entry</a> whose <a href=#url>URL</a> differs from that of the previous
- one only in the fragment identifier.</p>
+ <h5 id=the-hashchangeevent-interface><span class=secno>6.6.10.2 </span>The <code><a href=#hashchangeevent>HashChangeEvent</a></code> interface</h5>
+
<pre class=idl>[Constructor(DOMString type, optional <a href=#hashchangeeventinit>HashChangeEventInit</a> eventInitDict)]
interface <dfn id=hashchangeevent>HashChangeEvent</dfn> : <a href=#event>Event</a> {
readonly attribute DOMString <a href=#dom-hashchangeevent-oldurl title=dom-HashChangeEvent-oldURL>oldURL</a>;
@@ -68429,13 +68473,9 @@
</div>
- <hr><p>The <dfn id=event-pageshow title=event-pageshow><code>pageshow</code></dfn> event is fired when <a href=#traverse-the-history title="traverse the history">traversing</a> <em>to</em> a <a href=#session-history-entry>session history entry</a>.
- The <dfn id=event-pagehide title=event-pagehide><code>pagehide</code></dfn> event is fired when traversing
- <em>from</em> a <a href=#session-history-entry>session history entry</a>. The specification uses the <a href=#page-showing>page
- showing</a> flag to ensure that scripts receive these events in a consistent manner (e.g. that
- they never receive two <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a row without an
- intervening <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code>, or vice versa).</p>
+ <h5 id=the-pagetransitionevent-interface><span class=secno>6.6.10.3 </span>The <code><a href=#pagetransitionevent>PageTransitionEvent</a></code> interface</h5>
+
<pre class=idl>[Constructor(DOMString type, optional <a href=#pagetransitioneventinit>PageTransitionEventInit</a> eventInitDict)]
interface <dfn id=pagetransitionevent>PageTransitionEvent</dfn> : <a href=#event>Event</a> {
readonly attribute boolean <a href=#dom-pagetransitionevent-persisted title=dom-PageTransitionEvent-persisted>persisted</a>;
@@ -68450,7 +68490,7 @@
<dd>
<p>For the <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> event, returns false if the page is
- newly being loaded (and the <code title=event-load>load</code> event will fire). Otherwise,
+ newly being loaded (and the <code title=event-load><a href=#event-load>load</a></code> event will fire). Otherwise,
returns true.</p>
<p>For the <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> event, returns false if the page is
@@ -68461,8 +68501,8 @@
<p>Things that can cause the page to be unsalvageable include:</p>
<ul class=brief><li><code title=dom-document-open><a href=#dom-document-open>document.open()</a></code>
- <li>Listening for <code title=event-beforeunload>beforeunload</code> events
- <li>Listening for <code title=event-unload>unload</code> events
+ <li>Listening for <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> events
+ <li>Listening for <code title=event-unload><a href=#event-unload>unload</a></code> events
<li>Having <code><a href=#the-iframe-element>iframe</a></code>s that are not salvageable
<li>Active <code><a href=#websocket>WebSocket</a></code> objects
<li><a href=#abort-a-document title="abort a document">Aborting a <code>Document</code></a>
@@ -68482,9 +68522,12 @@
<div class=impl>
- <p>A <code><a href=#document>Document</a></code> has a <dfn id=concept-document-salvageable title=concept-document-salvageable><i>salvageable</i></dfn> state, which must initially be true,
- a <dfn id=fired-unload>fired unload</dfn> flag, which must initially be false, and a <dfn id=page-showing>page showing</dfn> flag,
- which must initially be false.</p>
+ <p>A <code><a href=#document>Document</a></code> has a <dfn id=concept-document-salvageable title=concept-document-salvageable><i>salvageable</i></dfn> state, which must initially be
+ true, a <dfn id=fired-unload>fired unload</dfn> flag, which must initially be false, and a <dfn id=page-showing>page showing</dfn>
+ flag, which must initially be false. The <a href=#page-showing>page showing</a> flag is used to ensure that
+ scripts receive <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> and <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a consistent manner (e.g. that they never
+ receive two <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a row without an intervening
+ <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code>, or vice versa).</p>
<p><a href=#event-loop title="event loop">Event loops</a> have a <dfn id=termination-nesting-level>termination nesting level</dfn>
counter, which must initially be zero.</p>
@@ -68499,7 +68542,7 @@
one.</li>
<li><p>Let <var title="">event</var> be a new <a href=#concept-events-trusted title=concept-events-trusted>trusted</a>
- <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> event object with the name <code title=event-beforeunload>beforeunload</code>, which does not bubble but is cancelable.</li>
+ <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> event object with the name <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code>, which does not bubble but is cancelable.</li>
<li><p><i>Dispatch</i>: <a href=#concept-event-dispatch title=concept-event-dispatch>Dispatch</a> <var title="">event</var> at the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object.</li>
@@ -68592,7 +68635,7 @@
</li>
<li><p><i>Unload event</i>: If the <code><a href=#document>Document</a></code>'s <a href=#fired-unload>fired unload</a> flag is
- false, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-unload>unload</code> at the
+ false, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-unload><a href=#event-unload>unload</a></code> at the
<code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object.</li>
<li><p>Decrease the <a href=#event-loop>event loop</a>'s <a href=#termination-nesting-level>termination nesting level</a> by
@@ -68659,10 +68702,12 @@
state is false, empty the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code>'s <a href=#list-of-active-timers>list of active
timers</a>.</li>
- </ol><h5 id=event-definition><span class=secno>6.6.11.1 </span>Event definition</h5>
+ </ol></div>
- </div>
+
+ <h5 id=the-beforeunloadevent-interface><span class=secno>6.6.11.1 </span>The <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> interface</h5>
+
<pre class=idl>interface <dfn id=beforeunloadevent>BeforeUnloadEvent</dfn> : <a href=#event>Event</a> {
attribute DOMString <a href=#dom-beforeunloadevent-returnvalue title=dom-BeforeUnloadEvent-returnValue>returnValue</a>;
};</pre>
@@ -68717,7 +68762,7 @@
</ol><p>User agents may allow users to explicitly invoke the <a href=#abort-a-document title="abort a document">abort a
document</a> algorithm for a <code><a href=#document>Document</a></code>. If the user does so, then, if that
<code><a href=#document>Document</a></code> is an <a href=#active-document>active document</a>, the user agent should <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-abort>abort</code> at
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-abort><a href=#event-abort>abort</a></code> at
that <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object before invoking the <a href=#abort-a-document title="abort a
document">abort</a> algorithm.</p>
@@ -69641,7 +69686,7 @@
progress</dfn>. Support for this is optional. Caching progress UI could consist of a progress bar
or message panel in the user agent's interface, or an overlay, or something else. Certain events
fired during the <a href=#application-cache-download-process>application cache download process</a> allow the script to override the
- display of such an interface. (Such events are delayed until after the <code title=event-load>load</code> event has fired.)
+ display of such an interface. (Such events are delayed until after the <code title=event-load><a href=#event-load>load</a></code> event has fired.)
The goal of this is to allow Web applications to provide more
seamless update mechanisms, hiding from the user the mechanics of the application cache mechanism.
@@ -70239,7 +70284,7 @@
site.</p>
<hr><p>Each <code><a href=#document>Document</a></code> has a list of <dfn id=pending-application-cache-download-process-tasks>pending application cache download process
- tasks</dfn> that is used to delay events fired by the algorithm above until the document's <code title=event-load>load</code> event has fired. When the <code><a href=#document>Document</a></code> is created, the
+ tasks</dfn> that is used to delay events fired by the algorithm above until the document's <code title=event-load><a href=#event-load>load</a></code> event has fired. When the <code><a href=#document>Document</a></code> is created, the
list must be empty.</p>
<p>When the steps above say to <dfn id=queue-a-post-load-task>queue a post-load task</dfn> <var title="">task</var>, where
@@ -70671,14 +70716,16 @@
requests a remote page (or knows that such an attempt would fail), and must return true
otherwise.</p>
+<!--CLEANUP-->
<p>When the value that would be returned by the <code title=dom-navigator-onLine><a href=#dom-navigator-online>navigator.onLine</a></code> attribute of a <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> changes from true to false, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-offline title=event-offline><code>offline</code></dfn> at the <code><a href=#window>Window</a></code> or
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-offline><a href=#event-offline>offline</a></code> at the <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object.</p>
+<!--CLEANUP-->
<p>On the other hand, when the value that would be returned by the <code title=dom-navigator-onLine><a href=#dom-navigator-online>navigator.onLine</a></code> attribute of a <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> changes from false to true, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-online title=event-online><code>online</code></dfn> at the <code><a href=#window>Window</a></code> or
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-online><a href=#event-online>online</a></code> at the <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object.</p>
<p>The <a href=#task-source>task source</a> for these <a href=#concept-task title=concept-task>tasks</a> is the
@@ -71204,7 +71251,7 @@
<a href=#browsing-context>browsing context</a>.</p>
<p class=example>For example, the prompt mentioned in the example above could also offer the
- user with a mechanism to just close the page entirely, without running any <code title=event-unload>unload</code> event handlers.</p>
+ user with a mechanism to just close the page entirely, without running any <code title=event-unload><a href=#event-unload>unload</a></code> event handlers.</p>
</div>
@@ -71262,7 +71309,7 @@
<li><p>Let <var title="">event</var> be a new <a href=#concept-events-trusted title=concept-events-trusted>trusted</a>
<code><a href=#errorevent>ErrorEvent</a></code> object that does not bubble but is cancelable, and which has the event
- name <code title=event-error>error</code>.</li>
+ name <code title=event-error><a href=#event-error>error</a></code>.</li>
<li><p>Initialize <var title="">event</var>'s <code title=dom-ErrorEvent-message><a href=#dom-errorevent-message>message</a></code>
attribute to <var title="">message</var>.</li>
@@ -71888,7 +71935,7 @@
<p class=note>The return value of the function affects whether the event is canceled or not:
<span class=impl>as described above,</span> if the return value is false, the event is canceled
(except for <code class=event-mouseover>mouseover</code> events, where the return value has to
- be true to cancel the event). With <code title=event-beforeunload>beforeunload</code> events,
+ be true to cancel the event). With <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> events,
the value is instead used to determine the message to show the user.</p>
<p>For historical reasons, the <code title=handler-onerror><a href=#handler-onerror>onerror</a></code> handler has different
@@ -72081,66 +72128,66 @@
attributes</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-onabort title=handler-onabort><code>onabort</code></dfn> <td> <code title=event-abort>abort</code>
+ <tbody><tr><td><dfn id=handler-onabort title=handler-onabort><code>onabort</code></dfn> <td> <code title=event-abort><a href=#event-abort>abort</a></code>
<tr><td><dfn id=handler-oncancel title=handler-oncancel><code>oncancel</code></dfn> <td> <code title=event-cancel><a href=#event-cancel>cancel</a></code>
<tr><td><dfn id=handler-oncanplay title=handler-oncanplay><code>oncanplay</code></dfn> <td> <code title=event-media-canplay><a href=#event-media-canplay>canplay</a></code>
<tr><td><dfn id=handler-oncanplaythrough title=handler-oncanplaythrough><code>oncanplaythrough</code></dfn> <td> <code title=event-media-canplaythrough><a href=#event-media-canplaythrough>canplaythrough</a></code>
- <tr><td><dfn id=handler-onchange title=handler-onchange><code>onchange</code></dfn> <td> <code title=event-change>change</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onchange title=handler-onchange><code>onchange</code></dfn> <td> <code title=event-change><a href=#event-change>change</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onclick title=handler-onclick><code>onclick</code></dfn> <td> <code title=event-click><a href=#event-click>click</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onclose title=handler-onclose><code>onclose</code></dfn> <td> <code title=event-close><a href=#event-close>close</a></code> <!-- new for <dialog> -->
- <tr><td><dfn id=handler-oncontextmenu title=handler-oncontextmenu><code>oncontextmenu</code></dfn> <td> <code title=event-contextmenu>contextmenu</code> <!-- widely used -->
- <tr><td><dfn id=handler-oncuechange title=handler-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-cuechange>cuechange</code>
- <tr><td><dfn id=handler-ondblclick title=handler-ondblclick><code>ondblclick</code></dfn> <td> <code title=event-dblclick>dblclick</code> <!-- widely used -->
- <tr><td><dfn id=handler-ondrag title=handler-ondrag><code>ondrag</code></dfn> <td> <code title=event-drag><a href=#event-drag>drag</a></code>
- <tr><td><dfn id=handler-ondragend title=handler-ondragend><code>ondragend</code></dfn> <td> <code title=event-dragend><a href=#event-dragend>dragend</a></code>
- <tr><td><dfn id=handler-ondragenter title=handler-ondragenter><code>ondragenter</code></dfn> <td> <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code>
- <tr><td><dfn id=handler-ondragexit title=handler-ondragexit><code>ondragexit</code></dfn> <td> <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>
- <tr><td><dfn id=handler-ondragleave title=handler-ondragleave><code>ondragleave</code></dfn> <td> <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>
- <tr><td><dfn id=handler-ondragover title=handler-ondragover><code>ondragover</code></dfn> <td> <code title=event-dragover><a href=#event-dragover>dragover</a></code>
- <tr><td><dfn id=handler-ondragstart title=handler-ondragstart><code>ondragstart</code></dfn> <td> <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> <!-- widely used -->
- <tr><td><dfn id=handler-ondrop title=handler-ondrop><code>ondrop</code></dfn> <td> <code title=event-drop><a href=#event-drop>drop</a></code>
+ <tr><td><dfn id=handler-oncontextmenu title=handler-oncontextmenu><code>oncontextmenu</code></dfn> <td> <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-oncuechange title=handler-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code>
+ <tr><td><dfn id=handler-ondblclick title=handler-ondblclick><code>ondblclick</code></dfn> <td> <code title=event-dblclick><a href=#event-dblclick>dblclick</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-ondrag title=handler-ondrag><code>ondrag</code></dfn> <td> <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code>
+ <tr><td><dfn id=handler-ondragend title=handler-ondragend><code>ondragend</code></dfn> <td> <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>
+ <tr><td><dfn id=handler-ondragenter title=handler-ondragenter><code>ondragenter</code></dfn> <td> <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code>
+ <tr><td><dfn id=handler-ondragexit title=handler-ondragexit><code>ondragexit</code></dfn> <td> <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>
+ <tr><td><dfn id=handler-ondragleave title=handler-ondragleave><code>ondragleave</code></dfn> <td> <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>
+ <tr><td><dfn id=handler-ondragover title=handler-ondragover><code>ondragover</code></dfn> <td> <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>
+ <tr><td><dfn id=handler-ondragstart title=handler-ondragstart><code>ondragstart</code></dfn> <td> <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-ondrop title=handler-ondrop><code>ondrop</code></dfn> <td> <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code>
<tr><td><dfn id=handler-ondurationchange title=handler-ondurationchange><code>ondurationchange</code></dfn> <td> <code title=event-media-durationchange><a href=#event-media-durationchange>durationchange</a></code>
<tr><td><dfn id=handler-onemptied title=handler-onemptied><code>onemptied</code></dfn> <td> <code title=event-media-emptied><a href=#event-media-emptied>emptied</a></code>
<tr><td><dfn id=handler-onended title=handler-onended><code>onended</code></dfn> <td> <code title=event-media-ended><a href=#event-media-ended>ended</a></code>
- <tr><td><dfn id=handler-oninput title=handler-oninput><code>oninput</code></dfn> <td> <code title=event-input>input</code>
- <tr><td><dfn id=handler-oninvalid title=handler-oninvalid><code>oninvalid</code></dfn> <td> <code title=event-invalid>invalid</code>
- <tr><td><dfn id=handler-onkeydown title=handler-onkeydown><code>onkeydown</code></dfn> <td> <code title=event-keydown>keydown</code> <!-- widely used -->
- <tr><td><dfn id=handler-onkeypress title=handler-onkeypress><code>onkeypress</code></dfn> <td> <code title=event-keypress>keypress</code> <!-- widely used -->
- <tr><td><dfn id=handler-onkeyup title=handler-onkeyup><code>onkeyup</code></dfn> <td> <code title=event-keyup>keyup</code> <!-- widely used -->
+ <tr><td><dfn id=handler-oninput title=handler-oninput><code>oninput</code></dfn> <td> <code title=event-input><a href=#event-input>input</a></code>
+ <tr><td><dfn id=handler-oninvalid title=handler-oninvalid><code>oninvalid</code></dfn> <td> <code title=event-invalid><a href=#event-invalid>invalid</a></code>
+ <tr><td><dfn id=handler-onkeydown title=handler-onkeydown><code>onkeydown</code></dfn> <td> <code title=event-keydown><a href=#event-keydown>keydown</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onkeypress title=handler-onkeypress><code>onkeypress</code></dfn> <td> <code title=event-keypress><a href=#event-keypress>keypress</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onkeyup title=handler-onkeyup><code>onkeyup</code></dfn> <td> <code title=event-keyup><a href=#event-keyup>keyup</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onloadeddata title=handler-onloadeddata><code>onloadeddata</code></dfn> <td> <code title=event-media-loadeddata><a href=#event-media-loadeddata>loadeddata</a></code>
<tr><td><dfn id=handler-onloadedmetadata title=handler-onloadedmetadata><code>onloadedmetadata</code></dfn> <td> <code title=event-media-loadedmetadata><a href=#event-media-loadedmetadata>loadedmetadata</a></code>
<tr><td><dfn id=handler-onloadstart title=handler-onloadstart><code>onloadstart</code></dfn> <td> <code title=event-media-loadstart><a href=#event-media-loadstart>loadstart</a></code>
- <tr><td><dfn id=handler-onmousedown title=handler-onmousedown><code>onmousedown</code></dfn> <td> <code title=event-mousedown>mousedown</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseenter title=handler-onmouseenter><code>onmouseenter</code></dfn> <td> <code title=event-mouseenter>mouseenter</code> <!-- compat -->
- <tr><td><dfn id=handler-onmouseleave title=handler-onmouseleave><code>onmouseleave</code></dfn> <td> <code title=event-mouseleave>mouseleave</code> <!-- compat -->
- <tr><td><dfn id=handler-onmousemove title=handler-onmousemove><code>onmousemove</code></dfn> <td> <code title=event-mousemove>mousemove</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseout title=handler-onmouseout><code>onmouseout</code></dfn> <td> <code title=event-mouseout>mouseout</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseover title=handler-onmouseover><code>onmouseover</code></dfn> <td> <code title=event-mouseover>mouseover</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseup title=handler-onmouseup><code>onmouseup</code></dfn> <td> <code title=event-mouseup>mouseup</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmousewheel title=handler-onmousewheel><code>onmousewheel</code></dfn> <td> <code title=event-mousewheel>mousewheel</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmousedown title=handler-onmousedown><code>onmousedown</code></dfn> <td> <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseenter title=handler-onmouseenter><code>onmouseenter</code></dfn> <td> <code title=event-mouseenter><a href=#event-mouseenter>mouseenter</a></code> <!-- compat -->
+ <tr><td><dfn id=handler-onmouseleave title=handler-onmouseleave><code>onmouseleave</code></dfn> <td> <code title=event-mouseleave><a href=#event-mouseleave>mouseleave</a></code> <!-- compat -->
+ <tr><td><dfn id=handler-onmousemove title=handler-onmousemove><code>onmousemove</code></dfn> <td> <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseout title=handler-onmouseout><code>onmouseout</code></dfn> <td> <code title=event-mouseout><a href=#event-mouseout>mouseout</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseover title=handler-onmouseover><code>onmouseover</code></dfn> <td> <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseup title=handler-onmouseup><code>onmouseup</code></dfn> <td> <code title=event-mouseup><a href=#event-mouseup>mouseup</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmousewheel title=handler-onmousewheel><code>onmousewheel</code></dfn> <td> <code title=event-mousewheel><a href=#event-mousewheel>mousewheel</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onpause title=handler-onpause><code>onpause</code></dfn> <td> <code title=event-media-pause><a href=#event-media-pause>pause</a></code>
<tr><td><dfn id=handler-onplay title=handler-onplay><code>onplay</code></dfn> <td> <code title=event-media-play><a href=#event-media-play>play</a></code>
<tr><td><dfn id=handler-onplaying title=handler-onplaying><code>onplaying</code></dfn> <td> <code title=event-media-playing><a href=#event-media-playing>playing</a></code>
<tr><td><dfn id=handler-onprogress title=handler-onprogress><code>onprogress</code></dfn> <td> <code title=event-media-progress><a href=#event-media-progress>progress</a></code>
<tr><td><dfn id=handler-onratechange title=handler-onratechange><code>onratechange</code></dfn> <td> <code title=event-media-ratechange><a href=#event-media-ratechange>ratechange</a></code>
- <tr><td><dfn id=handler-onreset title=handler-onreset><code>onreset</code></dfn> <td> <code title=event-reset>reset</code>
+ <tr><td><dfn id=handler-onreset title=handler-onreset><code>onreset</code></dfn> <td> <code title=event-reset><a href=#event-reset>reset</a></code>
<tr><td><dfn id=handler-onseeked title=handler-onseeked><code>onseeked</code></dfn> <td> <code title=event-media-seeked><a href=#event-media-seeked>seeked</a></code>
<tr><td><dfn id=handler-onseeking title=handler-onseeking><code>onseeking</code></dfn> <td> <code title=event-media-seeking><a href=#event-media-seeking>seeking</a></code>
- <tr><td><dfn id=handler-onselect title=handler-onselect><code>onselect</code></dfn> <td> <code title=event-select>select</code> <!-- widely used --> <!-- [CSSOM] -->
- <tr><td><dfn id=handler-onshow title=handler-onshow><code>onshow</code></dfn> <td> <code title=event-show>show</code>
- <tr><td><dfn id=handler-onsort title=handler-onsort><code>onsort</code></dfn> <td> <code title=event-sort>sort</code>
+ <tr><td><dfn id=handler-onselect title=handler-onselect><code>onselect</code></dfn> <td> <code title=event-select><a href=#event-select>select</a></code> <!-- widely used --> <!-- [CSSOM] -->
+ <tr><td><dfn id=handler-onshow title=handler-onshow><code>onshow</code></dfn> <td> <code title=event-show><a href=#event-show>show</a></code>
+ <tr><td><dfn id=handler-onsort title=handler-onsort><code>onsort</code></dfn> <td> <code title=event-sort><a href=#event-sort>sort</a></code>
<tr><td><dfn id=handler-onstalled title=handler-onstalled><code>onstalled</code></dfn> <td> <code title=event-media-stalled><a href=#event-media-stalled>stalled</a></code>
- <tr><td><dfn id=handler-onsubmit title=handler-onsubmit><code>onsubmit</code></dfn> <td> <code title=event-submit>submit</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onsubmit title=handler-onsubmit><code>onsubmit</code></dfn> <td> <code title=event-submit><a href=#event-submit>submit</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onsuspend title=handler-onsuspend><code>onsuspend</code></dfn> <td> <code title=event-media-suspend><a href=#event-media-suspend>suspend</a></code>
<tr><td><dfn id=handler-ontimeupdate title=handler-ontimeupdate><code>ontimeupdate</code></dfn> <td> <code title=event-media-timeupdate><a href=#event-media-timeupdate>timeupdate</a></code>
- <tr><td><dfn id=handler-ontoggle title=handler-ontoggle><code>ontoggle</code></dfn> <td> <code title=event-toggle>toggle</code>
+ <tr><td><dfn id=handler-ontoggle title=handler-ontoggle><code>ontoggle</code></dfn> <td> <code title=event-toggle><a href=#event-toggle>toggle</a></code>
<tr><td><dfn id=handler-onvolumechange title=handler-onvolumechange><code>onvolumechange</code></dfn> <td> <code title=event-media-volumechange><a href=#event-media-volumechange>volumechange</a></code>
<tr><td><dfn id=handler-onwaiting title=handler-onwaiting><code>onwaiting</code></dfn> <td> <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code>
<!-- not supported, use dnd: -->
-<!--<tr><td><dfn title="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code title="event-beforecopy">beforecopy</code>--> <!-- widely used -->
-<!--<tr><td><dfn title="handler-oncopy"><code>oncopy</code></dfn> <td> <code title="event-copy">copy</code>--> <!-- widely used -->
-<!--<tr><td><dfn title="handler-onpaste"><code>onpaste</code></dfn> <td> <code title="event-paste">paste</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code title="event-cp-beforecopy">beforecopy</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-oncopy"><code>oncopy</code></dfn> <td> <code title="event-cp-copy">copy</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-onpaste"><code>onpaste</code></dfn> <td> <code title="event-cp-paste">paste</code>--> <!-- widely used -->
<!-- not supported yet (v2?): -->
<!--<tr><td><dfn title="handler-onselectstart"><code>onselectstart</code></dfn> <td> <code title="event-selectstart">selectstart</code>--> <!-- widely used -->
</table><hr><p>The following are the <a href=#event-handlers>event handlers</a> (and their corresponding <a href=#event-handler-event-type title="event
@@ -72156,12 +72203,12 @@
<code>Window</code> object's <code>Document</code>s</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-onblur title=handler-onblur><code>onblur</code></dfn> <td> <code title=event-blur>blur</code> <!-- widely used -->
- <tr><td><dfn id=handler-onerror title=handler-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
- <tr><td><dfn id=handler-onfocus title=handler-onfocus><code>onfocus</code></dfn> <td> <code title=event-focus>focus</code> <!-- widely used -->
- <tr><td><dfn id=handler-onload title=handler-onload><code>onload</code></dfn> <td> <code title=event-load>load</code>
- <tr><td><dfn id=handler-onresize title=handler-onresize><code>onresize</code></dfn> <td> <code title=event-resize>resize</code>
- <tr><td><dfn id=handler-onscroll title=handler-onscroll><code>onscroll</code></dfn> <td> <code title=event-scroll>scroll</code>
+ <tbody><tr><td><dfn id=handler-onblur title=handler-onblur><code>onblur</code></dfn> <td> <code title=event-blur><a href=#event-blur>blur</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onerror title=handler-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+ <tr><td><dfn id=handler-onfocus title=handler-onfocus><code>onfocus</code></dfn> <td> <code title=event-focus><a href=#event-focus>focus</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onload title=handler-onload><code>onload</code></dfn> <td> <code title=event-load><a href=#event-load>load</a></code>
+ <tr><td><dfn id=handler-onresize title=handler-onresize><code>onresize</code></dfn> <td> <code title=event-resize><a href=#event-resize>resize</a></code>
+ <tr><td><dfn id=handler-onscroll title=handler-onscroll><code>onscroll</code></dfn> <td> <code title=event-scroll><a href=#event-scroll>scroll</a></code>
</table><hr><p>The following are the <a href=#event-handlers>event handlers</a> (and their corresponding <a href=#event-handler-event-type title="event
handler event type">event handler event types</a>) <span class=impl>that must be</span>
supported by <code><a href=#window>Window</a></code> objects, as <a href=#event-handler-idl-attributes>event handler IDL attributes</a> on the
@@ -72171,9 +72218,9 @@
<code>Window</code> object's <code>Document</code>s</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-window-onafterprint title=handler-window-onafterprint><code>onafterprint</code></dfn> <td> <code title=event-afterprint>afterprint</code>
- <tr><td><dfn id=handler-window-onbeforeprint title=handler-window-onbeforeprint><code>onbeforeprint</code></dfn> <td> <code title=event-beforeprint>beforeprint</code>
- <tr><td><dfn id=handler-window-onbeforeunload title=handler-window-onbeforeunload><code>onbeforeunload</code></dfn> <td> <code title=event-beforeunload>beforeunload</code>
+ <tbody><tr><td><dfn id=handler-window-onafterprint title=handler-window-onafterprint><code>onafterprint</code></dfn> <td> <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code>
+ <tr><td><dfn id=handler-window-onbeforeprint title=handler-window-onbeforeprint><code>onbeforeprint</code></dfn> <td> <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code>
+ <tr><td><dfn id=handler-window-onbeforeunload title=handler-window-onbeforeunload><code>onbeforeunload</code></dfn> <td> <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code>
<tr><td><dfn id=handler-window-onhashchange title=handler-window-onhashchange><code>onhashchange</code></dfn> <td> <code title=event-hashchange><a href=#event-hashchange>hashchange</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onmessage title=handler-window-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code> <!-- new for postMessage -->
<tr><td><dfn id=handler-window-onoffline title=handler-window-onoffline><code>onoffline</code></dfn> <td> <code title=event-offline><a href=#event-offline>offline</a></code> <!-- new -->
@@ -72182,7 +72229,7 @@
<tr><td><dfn id=handler-window-onpageshow title=handler-window-onpageshow><code>onpageshow</code></dfn> <td> <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onpopstate title=handler-window-onpopstate><code>onpopstate</code></dfn> <td> <code title=event-popstate><a href=#event-popstate>popstate</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onstorage title=handler-window-onstorage><code>onstorage</code></dfn> <td> <code title=event-storage><a href=#event-storage>storage</a></code> <!-- new -->
- <tr><td><dfn id=handler-window-onunload title=handler-window-onunload><code>onunload</code></dfn> <td> <code title=event-unload>unload</code> <!-- widely used -->
+ <tr><td><dfn id=handler-window-onunload title=handler-window-onunload><code>onunload</code></dfn> <td> <code title=event-unload><a href=#event-unload>unload</a></code> <!-- widely used -->
</table><hr><!-- this guy is only on Document and not on HTMLElement because otherwise HTMLScriptElement would
have it and that causes compatibility issues since IE fires readystatechange events on <script>,
not load events, and we can't fire both, and some sites try to decide which to look for based on
@@ -72316,7 +72363,7 @@
<h5 id=events-and-the-window-object><span class=secno>7.1.5.4 </span>Events and the <code><a href=#window>Window</a></code> object</h5>
<p>When an event is dispatched at a DOM node in a <code><a href=#document>Document</a></code> in a <a href=#browsing-context>browsing
- context</a>, if the event is not a <code title=event-load>load</code> event, the user agent
+ context</a>, if the event is not a <code title=event-load><a href=#event-load>load</a></code> event, the user agent
must act as if, for the purposes of <a href=#concept-event-dispatch title=concept-event-dispatch>event dispatching</a>,
the <code><a href=#window>Window</a></code> object is the parent of the <code><a href=#document>Document</a></code> object. <a href=#refsDOM>[DOM]</a></p>
@@ -72632,7 +72679,7 @@
<code><a href=#document>Document</a></code> object on which the method was invoked.</p>
<p class=note>This basically causes <code title=dom-document-open><a href=#dom-document-open>document.open()</a></code> to
- be ignored when it's called from a <code title=event-beforeunload>beforeunload</code> <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code>, or <code title=event-unload>unload</code> event
+ be ignored when it's called from a <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code>, or <code title=event-unload><a href=#event-unload>unload</a></code> event
handler while the <code><a href=#document>Document</a></code> is being unloaded.</p>
</li>
@@ -73412,11 +73459,11 @@
<li>
- <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-beforeprint>beforeprint</code> at the <code><a href=#window>Window</a></code> object of the
+ <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> at the <code><a href=#window>Window</a></code> object of the
<code><a href=#document>Document</a></code> that is being printed, as well as any <a href=#nested-browsing-context title="nested browsing
context">nested browsing contexts</a> in it.</p>
- <p class=example>The <code title=event-beforeprint>beforeprint</code> event can be used to
+ <p class=example>The <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> event can be used to
annotate the printed copy, for instance adding the time at which the document was printed.</p>
</li>
@@ -73440,11 +73487,11 @@
<li>
- <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-afterprint>afterprint</code> at the <code><a href=#window>Window</a></code> object of the
+ <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> at the <code><a href=#window>Window</a></code> object of the
<code><a href=#document>Document</a></code> that is being printed, as well as any <a href=#nested-browsing-context title="nested browsing
context">nested browsing contexts</a> in it.</p>
- <p class=example>The <code title=event-afterprint>afterprint</code> event can be used to
+ <p class=example>The <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> event can be used to
revert annotations added in the earlier event, as well as showing post-printing UI. For
instance, if a page is walking the user through the steps of applying for a home loan, the
script could automatically advance to the next step after having printed a form or other.</p>
@@ -75505,7 +75552,7 @@
<p class=example>For example, consider a page that consists of just a single <a href=#inert>inert</a>
paragraph positioned in the middle of a <code><a href=#the-body-element>body</a></code>. If a user moves their pointing device
from the <code><a href=#the-body-element>body</a></code> over to the <a href=#inert>inert</a> paragraph and clicks on the paragraph,
- no <code title=event-mouseover>mouseover</code> event would be fired, and the <code title=event-mousemove>mousemove</code> and <code title=event-click><a href=#event-click>click</a></code> events would
+ no <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> event would be fired, and the <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> and <code title=event-click><a href=#event-click>click</a></code> events would
be fired on the <code><a href=#the-body-element>body</a></code> element rather than the paragraph.</p>
<!--CLEANUP-->
@@ -75827,7 +75874,7 @@
</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-focus>focus</code> at the element.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-focus><a href=#event-focus>focus</a></code> at the element.</li>
<!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/723 -->
</ol><p>User agents must synchronously run the <a href=#focusing-steps>focusing steps</a> for an element whenever the
@@ -75837,11 +75884,11 @@
<ol><li><p>If the element is an <code><a href=#the-input-element>input</a></code> element, and the <code title=event-input-change><a href=#event-input-change>change</a></code> event applies to the element, and the element does not
have a defined <a href=#activation-behavior>activation behavior</a>, and the user has changed the element's <a href=#concept-fe-value title=concept-fe-value>value</a> or its list of <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> while the control was focused
- without committing that change, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element.</p>
+ without committing that change, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change><a href=#event-change>change</a></code> at the element.</p>
<li><p>Unfocus the element.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-blur>blur</code> at the element.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-blur><a href=#event-blur>blur</a></code> at the element.</li>
<!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/723 -->
</ol><p>When an element that is focused stops being a <a href=#focusable>focusable</a> element, or stops being
@@ -76603,7 +76650,7 @@
is.</p>
<p>On a visual medium with a pointing device, a drag operation could be the default action of a
- <code title=event-mousedown>mousedown</code> event that is followed by a series of <code title=event-mousemove>mousemove</code> events, and the drop could be triggered by the mouse
+ <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> event that is followed by a series of <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> events, and the drop could be triggered by the mouse
being released.</p>
<p>When using an input modality other than a pointing device, users would probably have to
@@ -76628,7 +76675,7 @@
<p><i>This section is non-normative.</i></p>
- <p>To make an element draggable is simple: give the element a <code title=attr-draggable><a href=#the-draggable-attribute>draggable</a></code> attribute, and set an event listener for <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> that stores the data being dragged.</p>
+ <p>To make an element draggable is simple: give the element a <code title=attr-draggable><a href=#the-draggable-attribute>draggable</a></code> attribute, and set an event listener for <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> that stores the data being dragged.</p>
<p>The event handler typically needs to check that it's not a text selection that is being
dragged, and then needs to store data into the <code><a href=#datatransfer>DataTransfer</a></code> object and set the
@@ -76664,11 +76711,11 @@
"<code>move</code>" to indicate that the data will be moved).</p>
<p class=note>Instead of using the <code title=attr-dropzone><a href=#the-dropzone-attribute>dropzone</a></code> attribute, a drop
- target can handle the <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> event (to report whether or
- not the drop target is to accept the drop) and the <code title=event-dragover><a href=#event-dragover>dragover</a></code>
+ target can handle the <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> event (to report whether or
+ not the drop target is to accept the drop) and the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>
event (to specify what feedback is to be shown to the user).</p>
- <p>The <code title=event-drop><a href=#event-drop>drop</a></code> event allows the actual drop to be performed. This
+ <p>The <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event allows the actual drop to be performed. This
event needs to be canceled, so that the <code title=dom-DataTransfer-DropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute's value can be used by the source
(otherwise it's reset).</p>
@@ -76697,7 +76744,7 @@
}
</script></pre>
- <hr><p>To remove the original element (the one that was dragged) from the display, the <code title=event-dragend><a href=#event-dragend>dragend</a></code> event can be used.</p>
+ <hr><p>To remove the original element (the one that was dragged) from the display, the <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event can be used.</p>
<p>For our example here, that means updating the original markup to handle that event:</p>
@@ -76809,7 +76856,7 @@
<dl><dt><dfn id=concept-dnd-rw title=concept-dnd-rw>Read/write mode</dfn></dt>
<dd>
- <p>For the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event. New data can be added to the
+ <p>For the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event. New data can be added to the
<a href=#drag-data-store>drag data store</a>.</p>
</dd>
@@ -76817,7 +76864,7 @@
<dt><dfn id=concept-dnd-ro title=concept-dnd-ro>Read-only mode</dfn></dt>
<dd>
- <p>For the <code title=event-drop><a href=#event-drop>drop</a></code> event. The list of items representing dragged
+ <p>For the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event. The list of items representing dragged
data can be read, including the data. No new data can be added.</p>
</dd>
@@ -76888,7 +76935,7 @@
<p>Returns the kinds of operations that are to be allowed.</p>
- <p>Can be set (during the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event), to change the
+ <p>Can be set (during the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event), to change the
allowed operations.</p>
<p>The possible values are "<code title="">none</code>", "<code title="">copy</code>", "<code title="">copyLink</code>", "<code title="">copyMove</code>", "<code title="">link</code>",
@@ -76921,7 +76968,7 @@
<dd>
- <p>Returns an array listing the formats that were set in the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event. In addition, if any files are being dragged,
+ <p>Returns an array listing the formats that were set in the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event. In addition, if any files are being dragged,
then one of the types will be the string "<code title="">Files</code>".</p>
</dd>
@@ -76977,7 +77024,7 @@
values must be ignored.</p>
<p>The <dfn id=dom-datatransfer-effectallowed title=dom-DataTransfer-effectAllowed><code>effectAllowed</code></dfn> attribute is
- used in the drag-and-drop processing model to initialize the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute during the <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> and <code title=event-dragover><a href=#event-dragover>dragover</a></code> events.
+ used in the drag-and-drop processing model to initialize the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute during the <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> and <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> events.
When the <code><a href=#datatransfer>DataTransfer</a></code> object is created, the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute is set to a string value. On
getting, it must return its current value. On setting, if <a href=#drag-data-store>drag data store</a>'s <a href=#drag-data-store-mode title="drag data store mode">mode</a> is the <a href=#concept-dnd-rw title=concept-dnd-rw>read/write
mode</a> and the new value is one of "<code title="">none</code>", "<code title="">copy</code>", "<code title="">copyLink</code>", "<code title="">copyMove</code>", "<code title="">link</code>", "<code title="">linkMove</code>", "<code title="">move</code>", "<code title="">all</code>", or "<code title="">uninitialized</code>", then the attribute's current value
@@ -77577,11 +77624,11 @@
<ol><li>
- <p>If <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>, set the
+ <p>If <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>, set the
<a href=#drag-data-store-mode>drag data store mode</a> to the <a href=#concept-dnd-rw title=concept-dnd-rw>read/write
mode</a>.</p>
- <p>If <var title="">e</var> is <code title=event-drop><a href=#event-drop>drop</a></code>, set the <a href=#drag-data-store-mode>drag data
+ <p>If <var title="">e</var> is <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code>, set the <a href=#drag-data-store-mode>drag data
store mode</a> to the <a href=#concept-dnd-ro title=concept-dnd-ro>read-only mode</a>.</p>
</li>
@@ -77595,10 +77642,10 @@
<li>
<p id=dropEffect-initialization>Set the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute to "<code title="">none</code>"
- if <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>, <code title=event-drag><a href=#event-drag>drag</a></code>, <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>, or <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>; to the value corresponding to the <a href=#current-drag-operation>current drag
- operation</a> if <var title="">e</var> is <code title=event-drop><a href=#event-drop>drop</a></code> or <code title=event-dragend><a href=#event-dragend>dragend</a></code>; and to a value based on the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute's value and the
+ if <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>, <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code>, <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>, or <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>; to the value corresponding to the <a href=#current-drag-operation>current drag
+ operation</a> if <var title="">e</var> is <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> or <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>; and to a value based on the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute's value and the
drag-and-drop source, as given by the following table, otherwise (i.e. if <var title="">e</var>
- is <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> or <code title=event-dragover><a href=#event-dragover>dragover</a></code>):</p>
+ is <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> or <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>):</p>
<table><thead><tr><th><code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code></th>
<th><code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code></th>
@@ -77642,7 +77689,7 @@
<p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> <code><a href=#dragevent>DragEvent</a></code> object
and initialize it to have the given name <var title="">e</var>, to bubble, to be cancelable
- unless <var title="">e</var> is <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>, <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>, or <code title=event-dragend><a href=#event-dragend>dragend</a></code>, and to
+ unless <var title="">e</var> is <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>, <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>, or <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>, and to
have the <code title=dom-UIEvent-detail><a href=#dom-uievent-detail>detail</a></code> attribute initialized to zero, the mouse
and key attributes initialized according to the state of the input devices as they would be for
user interaction events, the <code title="">relatedTarget</code> attribute initialized to null,
@@ -77659,7 +77706,7 @@
<code><a href=#dragevent>DragEvent</a></code> object at the specified target element.</li>
<li><p>Set the <a href=#drag-data-store-allowed-effects-state>drag data store allowed effects state</a> to the current value of <var title="">dataTransfer</var>'s <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code>
- attribute. (It can only have changed value if <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>.)</li>
+ attribute. (It can only have changed value if <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>.)</li>
<li><p>Set the <a href=#drag-data-store-mode>drag data store mode</a> back to the <a href=#concept-dnd-p title=concept-dnd-p>protected mode</a> if it was changed in the first step.</li>
@@ -77858,7 +77905,7 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> at the
<a href=#source-node>source node</a>.</p>
<p>If the event is canceled, then the drag-and-drop operation should not occur; abort these
@@ -77927,7 +77974,7 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-drag><a href=#event-drag>drag</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> at the
<a href=#source-node>source node</a>. If this event is canceled, the user agent must set the <a href=#current-drag-operation>current
drag operation</a> to "<code title="">none</code>" (no drag operation).</p>
@@ -77935,7 +77982,7 @@
<li>
- <p>If the <code title=event-drag><a href=#event-drag>drag</a></code> event was not canceled and the user has not ended
+ <p>If the <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event was not canceled and the user has not ended
the drag-and-drop operation, check the state of the drag-and-drop operation, as follows:</p>
<ol><li>
@@ -77943,7 +77990,7 @@
<p>If the user is indicating a different <a href=#immediate-user-selection>immediate user selection</a> than during the
last iteration (or if this is the first iteration), and if this <a href=#immediate-user-selection>immediate user
selection</a> is not the same as the <a href=#current-target-element>current target element</a>, then <a href=#fire-a-dnd-event>fire a
- DND event</a> named <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code> at the <a href=#current-target-element>current
+ DND event</a> named <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code> at the <a href=#current-target-element>current
target element</a>, and then update the <a href=#current-target-element>current target element</a> as follows:</p>
<dl class=switch><dt>If the new <a href=#immediate-user-selection>immediate user selection</a> is null</dt>
@@ -77960,7 +78007,7 @@
<dd>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at the
<a href=#immediate-user-selection>immediate user selection</a>.</p>
<p>If the event is canceled, then set the <a href=#current-target-element>current target element</a> to the
@@ -77994,7 +78041,7 @@
<p>If the <a href=#immediate-user-selection>immediate user selection</a> is <var title="">new target</var>, then
leave the <a href=#current-target-element>current target element</a> unchanged.</p>
- <p>Otherwise, <a href=#fire-a-dnd-event>fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at <var title="">new target</var>. Then, set the
+ <p>Otherwise, <a href=#fire-a-dnd-event>fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at <var title="">new target</var>. Then, set the
<a href=#current-target-element>current target element</a> to <var title="">new target</var>, regardless of
whether that event was canceled or not.</p>
@@ -78010,7 +78057,7 @@
<dd>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at
<a href=#the-body-element-0>the body element</a>, if there is one, or at the <code><a href=#document>Document</a></code> object, if
not. Then, set the <a href=#current-target-element>current target element</a> to <a href=#the-body-element-0>the body element</a>,
regardless of whether that event was canceled or not.</p>
@@ -78025,7 +78072,7 @@
<p>If the previous step caused the <a href=#current-target-element>current target element</a> to change, and if the
previous target element was not null or a part of a non-DOM document, then <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> at the previous target
+ event</a> named <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> at the previous target
element.</p>
</li>
@@ -78033,10 +78080,10 @@
<li>
<p>If the <a href=#current-target-element>current target element</a> is a DOM element, then <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragover><a href=#event-dragover>dragover</a></code> at this <a href=#current-target-element>current target
+ event</a> named <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> at this <a href=#current-target-element>current target
element</a>.</p>
- <p>If the <code title=event-dragover><a href=#event-dragover>dragover</a></code> event is not canceled, run the
+ <p>If the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event is not canceled, run the
appropriate step from the following list:</p>
<dl class=switch><dt>If the <a href=#current-target-element>current target element</a> is a text field (e.g. <code><a href=#the-textarea-element>textarea</a></code>,
@@ -78066,7 +78113,7 @@
<dd><p>Reset the <a href=#current-drag-operation>current drag operation</a> to "<code title="">none</code>".</dd>
- </dl><p>Otherwise (if the <code title=event-dragover><a href=#event-dragover>dragover</a></code> event <em>is</em> canceled),
+ </dl><p>Otherwise (if the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event <em>is</em> canceled),
set the <a href=#current-drag-operation>current drag operation</a> based on the values of the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> and <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attributes of the <code><a href=#dragevent>DragEvent</a></code>
object's <code title=dom-DragEvent-dataTransfer><a href=#dom-dragevent-datatransfer>dataTransfer</a></code> object as they stood
after the event <a href=#concept-event-dispatch title=concept-event-dispatch>dispatch</a> finished, as per the
@@ -78118,7 +78165,7 @@
<li>
<p>Otherwise, if the user ended the drag-and-drop operation (e.g. by releasing the mouse button
- in a mouse-driven drag-and-drop interface), or if the <code title=event-drag><a href=#event-drag>drag</a></code> event
+ in a mouse-driven drag-and-drop interface), or if the <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event
was canceled, then this will be the last iteration. Run the following steps, then stop the
drag-and-drop operation:</p>
@@ -78132,7 +78179,7 @@
<ol><li><p>Let <var title="">dropped</var> be false.</li>
<li><p>If the <a href=#current-target-element>current target element</a> is a DOM element, <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> at it; otherwise, if it is
+ event</a> named <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> at it; otherwise, if it is
not null, use platform-specific conventions for drag cancellation.</li>
<li><p>Set the <a href=#current-drag-operation>current drag operation</a> to "<code title="">none</code>".</li>
@@ -78142,7 +78189,7 @@
<ol><li><p>Let <var title="">dropped</var> be true.</li>
<li><p>If the <a href=#current-target-element>current target element</a> is a DOM element, <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-drop><a href=#event-drop>drop</a></code> at it; otherwise, use
+ event</a> named <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> at it; otherwise, use
platform-specific conventions for indicating a drop.</li>
<li>
@@ -78182,14 +78229,14 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragend><a href=#event-dragend>dragend</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> at the
<a href=#source-node>source node</a>.</p>
</li>
<li>
- <p>Run the appropriate steps from the following list as the default action of the <code title=event-dragend><a href=#event-dragend>dragend</a></code> event:</p>
+ <p>Run the appropriate steps from the following list as the default action of the <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event:</p>
<dl class=switch><dt>If <var title="">dropped</var> is true, the <a href=#current-target-element>current target element</a> is a
<i>text field</i> (see below), the <a href=#current-drag-operation>current drag operation</a> is "<code title="">move</code>", and the source of the drag-and-drop operation is a selection in the
@@ -78259,7 +78306,7 @@
<!-- <th> <code title="dom-DataTransfer-effectAllowed">effectAllowed</code> </th> -->
<th> <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> </th>
<th> Default Action </th>
- <tbody><tr><td><dfn id=event-dragstart title=event-dragstart><code>dragstart</code></dfn></td>
+ <tbody><tr><td><dfn id=event-dnd-dragstart title=event-dnd-dragstart><code>dragstart</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78267,7 +78314,7 @@
<!-- <td>"<code title="">uninitialized</code>"</td> -->
<td>"<code title="">none</code>"</td>
<td>Initiate the drag-and-drop operation</td>
- <tr><td><dfn id=event-drag title=event-drag><code>drag</code></dfn></td>
+ <tr><td><dfn id=event-dnd-drag title=event-dnd-drag><code>drag</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78275,7 +78322,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>Continue the drag-and-drop operation</td>
- <tr><td><dfn id=event-dragenter title=event-dragenter><code>dragenter</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragenter title=event-dnd-dragenter><code>dragenter</code></dfn></td>
<td><a href=#immediate-user-selection>Immediate user selection</a> or <a href=#the-body-element-0>the body element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78283,7 +78330,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#dropEffect-initialization>Based on <code>effectAllowed</code> value</a></td>
<td>Reject <a href=#immediate-user-selection>immediate user selection</a> as potential <a href=#current-target-element title="current target element">target element</a></td>
- <tr><td><dfn id=event-dragexit title=event-dragexit><code>dragexit</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragexit title=event-dnd-dragexit><code>dragexit</code></dfn></td>
<td><a href=#current-target-element title="current target element">Previous target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78291,7 +78338,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>None</td>
- <tr><td><dfn id=event-dragleave title=event-dragleave><code>dragleave</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragleave title=event-dnd-dragleave><code>dragleave</code></dfn></td>
<td><a href=#current-target-element title="current target element">Previous target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78299,7 +78346,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>None</td>
- <tr><td><dfn id=event-dragover title=event-dragover><code>dragover</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragover title=event-dnd-dragover><code>dragover</code></dfn></td>
<td><a href=#current-target-element>Current target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78307,7 +78354,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#dropEffect-initialization>Based on <code>effectAllowed</code> value</a></td>
<td>Reset the <a href=#current-drag-operation>current drag operation</a> to "none"</td>
- <tr><td><dfn id=event-drop title=event-drop><code>drop</code></dfn></td>
+ <tr><td><dfn id=event-dnd-drop title=event-dnd-drop><code>drop</code></dfn></td>
<td><a href=#current-target-element>Current target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78315,7 +78362,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#current-drag-operation>Current drag operation</a></td>
<td>Varies</td>
- <tr><td><dfn id=event-dragend title=event-dragend><code>dragend</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragend title=event-dnd-dragend><code>dragend</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78324,7 +78371,7 @@
<td><a href=#current-drag-operation>Current drag operation</a></td>
<td>Varies</td>
</table><p>Not shown in the above table: all these events bubble, and the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute always has the value it had
- after the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event, defaulting to "<code title="">uninitialized</code>" in the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event.</p>
+ after the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event, defaulting to "<code title="">uninitialized</code>" in the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event.</p>
@@ -78623,8 +78670,8 @@
the user agent should then follow the relevant platform-specific conventions for copy operations
(e.g. updating the clipboard).</p>
- <p>The events involved in this process are the <code title="event-dragstart">dragstart</code>,
- <code title="event-drag">drag</code>, and <code title="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragstart">dragstart</code>,
+ <code title="event-dnd-drag">drag</code>, and <code title="event-dnd-dragend">dragend</code> events.</p>
<h5>Cut to clipboard</h5>
@@ -78633,8 +78680,8 @@
copy operation (see the previous section), followed, if the copy was completed successfully, by <a
href="#contenteditable-delete">a selection delete operation</a>.</p>
- <p>The events involved in this process are the <code title="event-dragstart">dragstart</code>,
- <code title="event-drag">drag</code>, and <code title="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragstart">dragstart</code>,
+ <code title="event-dnd-drag">drag</code>, and <code title="event-dnd-dragend">dragend</code> events.</p>
<h5>Paste from clipboard</h5>
@@ -78647,9 +78694,9 @@
selection</span>) the element with the keyboard focus, and then ended the drag-and-drop operation
without canceling it.</p>
- <p>The events involved in this process are the <code title="event-dragenter">dragenter</code>,
- <code title="event-dragover">dragover</code>, <code title="event-dragexit">dragexit</code>, <code
- title="event-dragleave">dragleave</code>, and <code title="event-drop">drop</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragenter">dragenter</code>,
+ <code title="event-dnd-dragover">dragover</code>, <code title="event-dnd-dragexit">dragexit</code>, <code
+ title="event-dnd-dragleave">dragleave</code>, and <code title="event-dnd-drop">drop</code> events.</p>
<h5>Paste from selection</h5>
@@ -78671,13 +78718,13 @@
<h4 id=security-risks-in-the-drag-and-drop-model><span class=secno>8.7.9 </span>Security risks in the drag-and-drop model</h4>
<p>User agents must not make the data added to the <code><a href=#datatransfer>DataTransfer</a></code> object during the
- <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event available to scripts until the <code title=event-drop><a href=#event-drop>drop</a></code> event, because otherwise, if a user were to drag sensitive
+ <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event available to scripts until the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event, because otherwise, if a user were to drag sensitive
information from one document to a second document, crossing a hostile third document in the
process, the hostile document could intercept the data.</p>
<p>For the same reason, user agents must consider a drop to be successful only if the user
specifically ended the drag operation — if any scripts end the drag operation, it must be
- considered unsuccessful (canceled) and the <code title=event-drop><a href=#event-drop>drop</a></code> event must not be
+ considered unsuccessful (canceled) and the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event must not be
fired.</p>
<p>User agents should take care to not start drag-and-drop operations in response to script
@@ -78710,13 +78757,13 @@
- <h3 id=event-definitions-2><span class=secno>9.1 </span>Event definitions</h3>
+ <h3 id=the-messageevent-interfaces><span class=secno>9.1 </span>The <code><a href=#messageevent>MessageEvent</a></code> interfaces</h3>
<p>Messages in <a href=#server-sent-events>server-sent events</a>, <a href=#network>Web sockets</a>, <a href=#web-messaging>cross-document
- messaging</a>, <a href=#channel-messaging>channel messaging</a>, and <a href=#broadcasting-to-other-browsing-contexts>broadcast channels</a> use the <dfn id=event-message title=event-message><code>message</code></dfn> event. </p>
+ messaging</a>, <a href=#channel-messaging>channel messaging</a>, and <a href=#broadcasting-to-other-browsing-contexts>broadcast channels</a> use the
+ <code><a href=#messageevent>MessageEvent</a></code> interface for their <code title=event-message><a href=#event-message>message</a></code>
+ events:</p>
- <p>The following interface is defined for this event:</p>
-
<pre class=idl>[Constructor(DOMString type, optional <a href=#messageeventinit>MessageEventInit</a> eventInitDict)]
interface <dfn id=messageevent>MessageEvent</dfn> : <a href=#event>Event</a> {
readonly attribute any <a href=#dom-messageevent-data title=dom-MessageEvent-data>data</a>;
@@ -78774,8 +78821,9 @@
<dd>
+<!--CLEANUP-->
<p>Returns the <code><a href=#windowproxy>WindowProxy</a></code> of the source window, for <a href=#web-messaging>cross-document
- messaging</a>, and the <code><a href=#messageport>MessagePort</a></code> being attached, in the <code title=event-connect>connect</code> event fired at <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
+ messaging</a>, and the <code><a href=#messageport>MessagePort</a></code> being attached, in the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> event fired at <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
objects.</p>
</dd>
@@ -78813,7 +78861,7 @@
value it was initialized to. When the object is created, this attribute must be initialized to
null. It represents, in <a href=#web-messaging>cross-document messaging</a>, the <code><a href=#windowproxy>WindowProxy</a></code> of the
<a href=#browsing-context>browsing context</a> of the <code><a href=#window>Window</a></code> object from which the message came; and
- in the <code title=event-connect>connect</code> events used by <a href=#sharedworkerglobalscope title=SharedWorkerGlobalScope>shared workers</a>, the newly connecting
+ in the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> events used by <a href=#sharedworkerglobalscope title=SharedWorkerGlobalScope>shared workers</a>, the newly connecting
<code><a href=#messageport>MessagePort</a></code>.</p>
<p>The <dfn id=dom-messageevent-ports title=dom-MessageEvent-ports><code>ports</code></dfn> attribute must return the
@@ -79000,9 +79048,9 @@
interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-eventsource-onopen title=handler-EventSource-onopen><code>onopen</code></dfn> <td> <code title=event-open>open</code>
+ <tbody><tr><td><dfn id=handler-eventsource-onopen title=handler-EventSource-onopen><code>onopen</code></dfn> <td> <code title=event-open><a href=#event-open>open</a></code>
<tr><td><dfn id=handler-eventsource-onmessage title=handler-EventSource-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-eventsource-onerror title=handler-EventSource-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tr><td><dfn id=handler-eventsource-onerror title=handler-EventSource-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
</table><hr><p>In addition to the above, each <code><a href=#eventsource>EventSource</a></code> object has the following associated
with it:</p>
@@ -79090,7 +79138,7 @@
<hr><p>When a user agent is to <dfn id=announce-the-connection>announce the connection</dfn>, the user agent must <a href=#queue-a-task>queue a
task</a> which, if the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute is
set to a value other than <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code>, sets the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-OPEN><a href=#dom-eventsource-open>OPEN</a></code> and <a href=#fire-a-simple-event title="fire a simple event">fires a simple
- event</a> named <code title=event-open>open</code> at the <code><a href=#eventsource>EventSource</a></code>
+ event</a> named <code title=event-open><a href=#event-open>open</a></code> at the <code><a href=#eventsource>EventSource</a></code>
object.</p>
<p>When a user agent is to <dfn id=reestablish-the-connection>reestablish the connection</dfn>, the user agent must run the
@@ -79106,7 +79154,7 @@
<li><p>Set the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-CONNECTING><a href=#dom-eventsource-connecting>CONNECTING</a></code>.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-error>error</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the
<code><a href=#eventsource>EventSource</a></code> object.</li>
</ol></li>
@@ -79139,7 +79187,7 @@
</ol><p>When a user agent is to <dfn id=fail-the-connection>fail the connection</dfn>, the user agent must <a href=#queue-a-task>queue a
task</a> which, if the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute is
set to a value other than <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code>, sets the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code> and <a href=#fire-a-simple-event title="fire a simple event">fires a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#eventsource>EventSource</a></code> object.
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#eventsource>EventSource</a></code> object.
<strong>Once the user agent has <a href=#fail-the-connection title="fail the connection">failed the connection</a>, it
does <em>not</em> attempt to reconnect!</strong></p>
@@ -79498,13 +79546,13 @@
<h4 id=garbage-collection-0><span class=secno>9.2.8 </span>Garbage collection</h4>
<p>While an <code><a href=#eventsource>EventSource</a></code> object's <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> is <code title=dom-EventSource-CONNECTING><a href=#dom-eventsource-connecting>CONNECTING</a></code>, and the object has one or more event
- listeners registered for <code title=event-open>open</code>, <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error>error</code> events, there must
+ listeners registered for <code title=event-open><a href=#event-open>open</a></code>, <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error><a href=#event-error>error</a></code> events, there must
be a strong reference from the <code><a href=#window>Window</a></code> or <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object that
the <code><a href=#eventsource>EventSource</a></code> object's constructor was invoked from to the <code><a href=#eventsource>EventSource</a></code>
object itself.</p>
<p>While an <code><a href=#eventsource>EventSource</a></code> object's <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> is <code title=dom-EventSource-OPEN><a href=#dom-eventsource-open>OPEN</a></code>, and the object has one or more event listeners
- registered for <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error>error</code> events, there must be a strong reference from the
+ registered for <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error><a href=#event-error>error</a></code> events, there must be a strong reference from the
<code><a href=#window>Window</a></code> or <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object that the <code><a href=#eventsource>EventSource</a></code>
object's constructor was invoked from to the <code><a href=#eventsource>EventSource</a></code> object itself.</p>
@@ -79544,7 +79592,7 @@
parsed, and so forth.</p>
<p>Implementations are especially encouraged to report detailed information to their development
- consoles whenever an <code title=event-error>error</code> event is fired, since little to no
+ consoles whenever an <code title=event-error><a href=#event-error>error</a></code> event is fired, since little to no
information can be made available in the events themselves.</p>
@@ -79782,7 +79830,7 @@
<p class=note>If the <i><a href=#establish-a-websocket-connection>establish a WebSocket connection</a></i> algorithm fails, it triggers the
<i><a href=#fail-the-websocket-connection>fail the WebSocket connection</a></i> algorithm, which then invokes the <i><a href=#close-the-websocket-connection>close the WebSocket
connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the WebSocket connection is closed</a></i>,
- which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as
+ which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as
described below</a>.</p>
</li>
@@ -79864,7 +79912,7 @@
<p>Do nothing.</p>
<p class=note>The connection is already closing or is already closed. If it has not already,
- a <code title=event-socket-close>close</code> event will eventually fire <a href=#closeWebSocket>as described below</a>.</p>
+ a <code title=event-close><a href=#event-close>close</a></code> event will eventually fire <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -79878,7 +79926,7 @@
<p class=note>The <i><a href=#fail-the-websocket-connection>fail the WebSocket connection</a></i> algorithm invokes the <i><a href=#close-the-websocket-connection>close the
WebSocket connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the WebSocket connection is
- closed</a></i>, which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as described below</a>.</p>
+ closed</a></i>, which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -79899,7 +79947,7 @@
<p class=note>The <i><a href=#start-the-websocket-closing-handshake>start the WebSocket closing handshake</a></i> algorithm eventually invokes
the <i><a href=#close-the-websocket-connection>close the WebSocket connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the
- WebSocket connection is closed</a></i>, which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as described
+ WebSocket connection is closed</a></i>, which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as described
below</a>.</p>
</dd>
@@ -79913,7 +79961,7 @@
<p class=note><i><a href=#the-websocket-closing-handshake-is-started>The WebSocket closing handshake is started</a></i>, and will eventually invoke
the <i><a href=#close-the-websocket-connection>close the WebSocket connection</a></i> algorithm, which will establish that <i><a href=#the-websocket-connection-is-closed>the
- WebSocket connection is closed</a></i>, and thus the <code title=event-socket-close>close</code>
+ WebSocket connection is closed</a></i>, and thus the <code title=event-close><a href=#event-close>close</a></code>
event will fire, <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -80064,10 +80112,10 @@
by all objects implementing the <code><a href=#websocket>WebSocket</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-websocket-onopen title=handler-WebSocket-onopen><code>onopen</code></dfn> <td> <code title=event-open>open</code>
+ <tbody><tr><td><dfn id=handler-websocket-onopen title=handler-WebSocket-onopen><code>onopen</code></dfn> <td> <code title=event-open><a href=#event-open>open</a></code>
<tr><td><dfn id=handler-websocket-onmessage title=handler-WebSocket-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-websocket-onerror title=handler-WebSocket-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
- <tr><td><dfn id=handler-websocket-onclose title=handler-WebSocket-onclose><code>onclose</code></dfn> <td> <code title=event-socket-close>close</code>
+ <tr><td><dfn id=handler-websocket-onerror title=handler-WebSocket-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+ <tr><td><dfn id=handler-websocket-onclose title=handler-WebSocket-onclose><code>onclose</code></dfn> <td> <code title=event-close><a href=#event-close>close</a></code>
</table><h4 id=feedback-from-the-protocol><span class=secno>9.3.3 </span>Feedback from the protocol</h4>
<p>When <i><a href=#the-websocket-connection-is-established>the WebSocket connection is established</a></i>, the user agent must <a href=#queue-a-task>queue a
@@ -80091,7 +80139,7 @@
set-cookie-string</a> consisting of the <i><a href="#cookies-set-during-the-server's-opening-handshake">cookies set during the server's opening
handshake</a></i>, for the URL <var title="">url</var> given to the <code title=dom-WebSocket><a href=#dom-websocket>WebSocket()</a></code> constructor. <a href=#refsCOOKIES>[COOKIES]</a> <a href=#refsRFC3629>[RFC3629]</a> <a href=#refsWSP>[WSP]</a></li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-open>open</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-open><a href=#event-open>open</a></code> at the
<code><a href=#websocket>WebSocket</a></code> object.</p>
</ol><hr><p>When <i><a href=#a-websocket-message-has-been-received>a WebSocket message has been received</a></i> with type <var title="">type</var> and data
@@ -80179,7 +80227,7 @@
object. <a href=#refsWSP>[WSP]</a></li>
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#closeevent>CloseEvent</a></code> interface, with the event type <code title=event-socket-close>close</code>, which does not bubble, is not cancelable, has no default
+ <code><a href=#closeevent>CloseEvent</a></code> interface, with the event type <code title=event-close><a href=#event-close>close</a></code>, which does not bubble, is not cancelable, has no default
action, whose <code title=dom-CloseEvent-wasClean><a href=#dom-closeevent-wasclean>wasClean</a></code> attribute is initialized to
true if the connection closed <i title="">cleanly</i> and false otherwise, whose <code title=dom-CloseEvent-code><a href=#dom-closeevent-code>code</a></code> attribute is initialized to <i><a href=#the-websocket-connection-close-code>the WebSocket connection
close code</a></i>, and whose <code title=dom-CloseEvent-reason><a href=#dom-closeevent-reason>reason</a></code> attribute is
@@ -80294,7 +80342,7 @@
<li><p>Return <var title="">host</var>, <var title="">port</var>, <var title="">resource
name</var>, and <var title="">secure</var>.</li>
- </ol><h4 id=event-definitions-3><span class=secno>9.3.6 </span>Event definitions</h4>
+ </ol><h4 id=the-closeevent-interfaces><span class=secno>9.3.6 </span>The <code><a href=#closeevent>CloseEvent</a></code> interfaces</h4>
<pre class=idl>[Constructor(DOMString type, optional <a href=#closeeventinit>CloseEventInit</a> eventInitDict)]
interface <dfn id=closeevent>CloseEvent</dfn> : <a href=#event>Event</a> {
@@ -80328,18 +80376,18 @@
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-CONNECTING><a href=#dom-websocket-connecting>CONNECTING</a></code> (0) as of
the last time the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must not be garbage collected if there are any event listeners
- registered for <code title=event-open>open</code> events, <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error>error</code> events, or
- <code title=event-socket-close>close</code> events.</p>
+ registered for <code title=event-open><a href=#event-open>open</a></code> events, <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error><a href=#event-error>error</a></code> events, or
+ <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-OPEN><a href=#dom-websocket-open>OPEN</a></code> (1) as of the last time
the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must not be
- garbage collected if there are any event listeners registered for <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error>error</code>, or <code title=event-socket-close>close</code> events.</p>
+ garbage collected if there are any event listeners registered for <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error><a href=#event-error>error</a></code>, or <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-CLOSING><a href=#dom-websocket-closing>CLOSING</a></code> (2) as of the last
time the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must
- not be garbage collected if there are any event listeners registered for <code title=event-error>error</code> or <code title=event-socket-close>close</code> events.</p>
+ not be garbage collected if there are any event listeners registered for <code title=event-error><a href=#event-error>error</a></code> or <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object with <i title="the WebSocket connection is established"><a href=#the-websocket-connection-is-established>an
established connection</a></i> that has data queued to be transmitted to the network must not be
@@ -80794,7 +80842,7 @@
<code><a href=#the-iframe-element>iframe</a></code> to receive a <code title=event-hashchange><a href=#event-hashchange>hashchange</a></code> event.</li>
<li>Resize the <code><a href=#the-iframe-element>iframe</a></code>, causing the <code><a href=#window>Window</a></code> in the <code><a href=#the-iframe-element>iframe</a></code> to
- receive a <code title=event-resize>resize</code> event.</li>
+ receive a <code title=event-resize><a href=#event-resize>resize</a></code> event.</li>
<!-- anything else? -->
@@ -81065,7 +81113,7 @@
<li><p>If <var title="">original port</var> is <a href=#related-to-an-ill-fated-port>related to an ill-fated port</a>, then
create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a
- simple event</a> named <code title=event-error>error</code> at the <var title="">new
+ simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <var title="">new
port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message
queue</a> of <var title="">new port</var>. The <a href=#concept-task title=concept-task>task</a> must
be associated with the <a href=#responsible-document>responsible document</a> specified by <var title="">new
@@ -81318,7 +81366,7 @@
port</dfn>.</li>
<!--CLEANUP-->
- <li><p>Create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a simple event</a> named <code title=event-error>error</code> at <var title="">target port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message queue</a> of <var title="">target port</var>. The <a href=#concept-task title=concept-task>task</a> must be associated with the <a href=#responsible-document>responsible document</a>
+ <li><p>Create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at <var title="">target port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message queue</a> of <var title="">target port</var>. The <a href=#concept-task title=concept-task>task</a> must be associated with the <a href=#responsible-document>responsible document</a>
specified by <var title="">source port</var>'s <a href=#concept-port-owner title=concept-port-owner>owner</a>.</li>
<li><p>Disentangle the two ports.</li>
@@ -81335,7 +81383,7 @@
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
<tbody><tr><td><dfn id=handler-messageport-onmessage title=handler-MessagePort-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-messageport-onerror title=handler-MessagePort-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tr><td><dfn id=handler-messageport-onerror title=handler-MessagePort-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
</table><p>The first time a <code><a href=#messageport>MessagePort</a></code> object's <code title=handler-MessagePort-onmessage><a href=#handler-messageport-onmessage>onmessage</a></code> IDL attribute is set, the port's <a href=#port-message-queue>port
message queue</a> must be enabled, as if the <code title=dom-MessagePort-start><a href=#dom-messageport-start>start()</a></code>
method had been called.</p>
@@ -82678,7 +82726,8 @@
worker.port.postMessage('some message');
worker.port.postMessage({ foo: 'structured', bar: ['data', 'also', 'possible']});</pre>
- <p>Inside the shared worker, new clients of the worker are announced using the <code title=event-connect>connect</code> event. The port for the new client is given by the event
+<!--CLEANUP-->
+ <p>Inside the shared worker, new clients of the worker are announced using the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> event. The port for the new client is given by the event
object's <code title=dom-messageevent-source><a href=#dom-messageevent-source>source</a></code> attribute.</p>
<pre>onconnect = function (event) {
@@ -82738,7 +82787,7 @@
<!-- v2-onclose (remember to specify the task source, too)
<li><p><span>Queue a task</span> to <span>fire a simple event</span> named <code
- title="event-worker-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
+ title="event-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
-->
<li><p>Set the worker's <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag to true. (This prevents any further
@@ -82749,7 +82798,7 @@
by objects implementing the <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><!-- v2-onclose <tr><td><dfn title="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code title="event-worker-close">close</code> --><tr><td><dfn id=handler-workerglobalscope-onerror title=handler-WorkerGlobalScope-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tbody><!-- v2-onclose <tr><td><dfn title="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code title="event-close">close</code> --><tr><td><dfn id=handler-workerglobalscope-onerror title=handler-WorkerGlobalScope-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
<tr><td><dfn id=handler-workerglobalscope-onoffline title=handler-WorkerGlobalScope-onoffline><code>onoffline</code></dfn> <td> <code title=event-offline><a href=#event-offline>offline</a></code> <!-- new -->
<tr><td><dfn id=handler-workerglobalscope-ononline title=handler-WorkerGlobalScope-ononline><code>ononline</code></dfn> <td> <code title=event-online><a href=#event-online>online</a></code> <!-- new -->
</table><hr><!--CLEANUP--><p class=note>For <a href=#data-protocol title="data protocol"><code title="">data:</code> URLs</a>, this is
@@ -82817,7 +82866,7 @@
JavaScript</a> if the <a href=#javascript-global-environment>JavaScript global environment</a> is a <a href=#shared-worker-environment>shared worker
environment</a>.</p>
- <p>Shared workers receive message ports through <code title=event-WorkerGlobalScope-connect>connect</code> events on their <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code> object for each
+ <p>Shared workers receive message ports through <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> events on their <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code> object for each
connection.</p>
<p>The <dfn id=dom-sharedworkerglobalscope-name title=dom-SharedWorkerGlobalScope-name><code>name</code></dfn> attribute must return
@@ -82831,7 +82880,7 @@
interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-sharedworkerglobalscope-onconnect title=handler-SharedWorkerGlobalScope-onconnect><code>onconnect</code></dfn> <td> <code title=event-connect>connect</code>
+ <tbody><tr><td><dfn id=handler-sharedworkerglobalscope-onconnect title=handler-SharedWorkerGlobalScope-onconnect><code>onconnect</code></dfn> <td> <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>
</table><p>For the purposes of the <a href=#application-cache>application cache</a> networking model, a shared worker is its
own <a href=#cache-host>cache host</a>. The <a href=#run-a-worker>run a worker</a> algorithm takes care of associating the
worker with an <a href=#application-cache>application cache</a>.</p>
@@ -82959,7 +83008,7 @@
<p>If the attempt fails, then for each <code><a href=#worker>Worker</a></code> or <code><a href=#sharedworker>SharedWorker</a></code> object
associated with <var title="">worker global scope</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at that object. Abort these
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at that object. Abort these
steps.</p>
<p>If the attempt succeeds, then let <var title="">source</var> be the result of running the
@@ -83006,7 +83055,7 @@
no later than it stops being a <a href=#permissible-worker>permissible worker</a>, <var title="">worker global
scope</var>'s <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag is set to true<!--
v2-onclose and <span title="queue a task">a task is queued</span> to <span>fire a simple
- event</span> named <code title="event-worker-close">close</code> at <var title="">worker global
+ event</span> named <code title="event-close">close</code> at <var title="">worker global
scope</var>-->.</p>
</li>
@@ -83072,7 +83121,7 @@
<p>For each <code>Worker</code> or <code>SharedWorker</code> object associated with <var
title="">worker global scope</var>, <span>queue a task</span> to <span>fire a simple
- event</span> named <code title="event-worker-close">close</code> at that object.</p>
+ event</span> named <code title="event-close">close</code> at that object.</p>
</li>
-->
@@ -83091,32 +83140,32 @@
<ol><!-- v2-onclose
<li><p>If the worker's <code>WorkerGlobalScope</code> object's <span
title="dom-WorkerGlobalScope-closing">closing</span> flag is false, <span>queue a task</span> to
- <span>fire a simple event</span> named <code title="event-worker-close">close</code> at the
+ <span>fire a simple event</span> named <code title="event-close">close</code> at the
worker's <code>WorkerGlobalScope</code> object.</p></li>
--><li><p>Set the worker's <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag to true.</li>
<!-- v2-onclose
<li><p>Wait a user-agent-defined amount of time. If the "<span>run a worker</span>" processing
model defined above immediately starts running event listeners registered for the <code
- title="event-worker-close">close</code> event, this time should not be zero — the idea is
- that the <code title="event-worker-close">close</code> event can be used to clean up when
+ title="event-close">close</code> event, this time should not be zero — the idea is
+ that the <code title="event-close">close</code> event can be used to clean up when
shutting down unexpectedly.</p></li>
-->
<li><p>If there are any <a href=#concept-task title=concept-task>tasks</a> queued in the
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#event-loop>event loop</a>'s <a href=#task-queue title="task queue">task
- queues</a><!-- v2-onclose other than the <code title="event-worker-close">close</code> event
+ queues</a><!-- v2-onclose other than the <code title="event-close">close</code> event
that this algorithm just added-->, discard them without processing them.</li>
<!-- v2-onclose
- <li><p>If the <code title="event-worker-close">close</code> event that this algorithm just queued
+ <li><p>If the <code title="event-close">close</code> event that this algorithm just queued
hasn't yet been dispatched, then abort the script currently running in the worker.</p></li>
-->
<li><p>Wait a user-agent-defined amount of time.</li>
<li><p>Abort the script currently running in the worker<!-- v2-onclose (if any script is running,
- then it will be a handler for the <code title="event-worker-close">close</code>
+ then it will be a handler for the <code title="event-close">close</code>
event)-->.</li>
</ol><p>User agents may invoke the "<a href=#kill-a-worker>kill a worker</a>" processing model on a worker at any
@@ -83160,7 +83209,7 @@
<p>For dedicated workers, if the error is still <i title=concept-error-nothandled><a href=#concept-error-nothandled>not
handled</a></i> afterwards, the user
agent must <a href=#queue-a-task>queue a task</a> to <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the <code><a href=#errorevent>ErrorEvent</a></code>
- interface, with the name <code title=event-error>error</code>, that doesn't bubble and is
+ interface, with the name <code title=event-error><a href=#event-error>error</a></code>, that doesn't bubble and is
cancelable, with its <code title=dom-ErrorEvent-message><a href=#dom-errorevent-message>message</a></code>, <code title=dom-ErrorEvent-filename><a href=#dom-errorevent-filename>filename</a></code>, <code title=dom-ErrorEvent-lineno><a href=#dom-errorevent-lineno>lineno</a></code>, <code title=dom-ErrorEvent-colno><a href=#dom-errorevent-colno>colno</a></code>,
attributes initialized appropriately,
and with the <code title=dom-ErrorEvent-error><a href=#dom-errorevent-error>error</a></code> attribute initialized to null,
@@ -83171,7 +83220,7 @@
<p>If the implicit port connecting the worker to its <code><a href=#worker>Worker</a></code> object has been
disentangled (i.e. if the parent worker has been terminated), then the user agent must act as if
- the <code><a href=#worker>Worker</a></code> object had no <code title=event-error>error</code> event handler and as
+ the <code><a href=#worker>Worker</a></code> object had no <code title=event-error><a href=#event-error>error</a></code> event handler and as
if that worker's <code title=handler-WorkerGlobalScope-onerror><a href=#handler-workerglobalscope-onerror>onerror</a></code> attribute was
null, but must otherwise act as described above.</p>
@@ -83199,8 +83248,8 @@
objects implementing the <code><a href=#abstractworker>AbstractWorker</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-abstractworker-onerror title=handler-AbstractWorker-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
-<!-- v2-onclose <tr><td><dfn title="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code title="event-worker-close">close</code> -->
+ <tbody><tr><td><dfn id=handler-abstractworker-onerror title=handler-AbstractWorker-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+<!-- v2-onclose <tr><td><dfn title="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code title="event-close">close</code> -->
</table><h5 id=script-settings-for-workers><span class=secno>10.2.6.2 </span>Script settings for workers</h5>
<!--CLEANUP-->
@@ -83576,8 +83625,9 @@
<li><p><a href=#entangle>Entangle</a> <var title="">outside port</var>
and <var title="">inside port</var>.</li>
+<!--CLEANUP-->
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-connect>connect</code>, which does not bubble, is not cancelable, has no
+ <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>, which does not bubble, is not cancelable, has no
default action, has a <code title=dom-MessageEvent-data><a href=#dom-messageevent-data>data</a></code> attribute whose value
is initialized to the empty string, has a <code title=dom-MessageEvent-ports><a href=#dom-messageevent-ports>ports</a></code>
attribute whose value is initialized to a <a href=#dfn-read-only-array title=dfn-read-only-array>read only</a>
@@ -83634,8 +83684,9 @@
<li><p>Return <var title="">worker</var> and perform the remaining steps asynchronously.</li>
+<!--CLEANUP-->
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-connect>connect</code>,
+ <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>,
which does not bubble, is not cancelable, has no default action, has a <code title=dom-MessageEvent-data><a href=#dom-messageevent-data>data</a></code> attribute whose value is initialized to the empty
string, has a <code title=dom-MessageEvent-ports><a href=#dom-messageevent-ports>ports</a></code> attribute whose value is
initialized to a <a href=#dfn-read-only-array title=dfn-read-only-array>read only</a> array containing only the
@@ -84127,7 +84178,8 @@
<h4 id=the-storage-event><span class=secno>11.2.4 </span>The <code title=event-storage><a href=#event-storage>storage</a></code> event</h4>
- <p>The <dfn id=event-storage title=event-storage><code>storage</code></dfn> event is fired on a
+<!--CLEANUP-->
+ <p>The <code title=event-storage><a href=#event-storage>storage</a></code> event is fired on a
<code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object when a storage area changes, as described in
the previous two sections (<a href=#sessionStorageEvent>for session storage</a>, <a href=#localStorageEvent>for local storage</a>).</p>
@@ -84159,7 +84211,7 @@
(i.e. session or local).</p>
- <h5 id=event-definition-0><span class=secno>11.2.4.1 </span>Event definition</h5>
+ <h5 id=the-storageevent-interface><span class=secno>11.2.4.1 </span>The <code><a href=#storageevent>StorageEvent</a></code> interface</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#storageeventinit>StorageEventInit</a> eventInitDict)]
interface <dfn id=storageevent>StorageEvent</dfn> : <a href=#event>Event</a> {
@@ -92710,7 +92762,7 @@
</ol></li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-DOMContentLoaded>DOMContentLoaded</code> at the <code><a href=#document>Document</a></code>.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-DOMContentLoaded><a href=#event-domcontentloaded>DOMContentLoaded</a></code> at the <code><a href=#document>Document</a></code>.</li>
<li><p><a href=#spin-the-event-loop>Spin the event loop</a> until the <a href=#set-of-scripts-that-will-execute-as-soon-as-possible>set of scripts that will execute as soon
as possible</a> and the <a href=#list-of-scripts-that-will-execute-in-order-as-soon-as-possible>list of scripts that will execute in order as soon as
@@ -92729,7 +92781,7 @@
<ol><li><p>Set the <a href=#current-document-readiness>current document readiness</a> to "<code title="">complete</code>"<!--
this also fires an event synchronously during the task -->.</li>
- <li><p>If the <code><a href=#document>Document</a></code> is in a <a href=#browsing-context>browsing context</a>, create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event named <code title=event-load>load</code> that does not bubble and is not cancelable and which uses the
+ <li><p>If the <code><a href=#document>Document</a></code> is in a <a href=#browsing-context>browsing context</a>, create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event named <code title=event-load><a href=#event-load>load</a></code> that does not bubble and is not cancelable and which uses the
<code><a href=#event>Event</a></code> interface, and <a href=#concept-event-dispatch title=concept-event-dispatch>dispatch</a> it at
the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object, with <i>target override</i> set to the
<code><a href=#document>Document</a></code> object.</li>
@@ -96919,7 +96971,7 @@
<code><a href=#the-marquee-element>marquee</a></code> element must be <a href=#concept-marquee-off title=concept-marquee-off>turned off</a>.</p>
<p>When a <code><a href=#the-marquee-element>marquee</a></code> element is created, the user agent must <a href=#queue-a-task>queue a task</a>
- to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-start>start</code> at the
+ to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-start>start</code> at the
element.</p>
<hr><p>The <dfn id=attr-marquee-behavior title=attr-marquee-behavior><code>behavior</code></dfn> content attribute on
@@ -97001,14 +97053,14 @@
<p>If the <a href=#marquee-current-loop-index>marquee current loop index</a> is now equal to or greater than the element's
<a href=#marquee-loop-count>marquee loop count</a>, <a href=#concept-marquee-off title=concept-marquee-off>turn off</a> the
<code><a href=#the-marquee-element>marquee</a></code> element and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-finish>finish</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
+ named <code title=event-marquee-finish>finish</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
<p>Otherwise, if the <code title=attr-marquee-behavior><a href=#attr-marquee-behavior>behavior</a></code> attribute is in the
<a href=#attr-marquee-behavior-alternate title=attr-marquee-behavior-alternate>alternate</a> state, then <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-bounce>bounce</code>
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-bounce>bounce</code>
at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
- <p>Otherwise, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-start>start</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
+ <p>Otherwise, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-start>start</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
</li>
@@ -97017,9 +97069,9 @@
attributes</a>, by <code><a href=#the-marquee-element>marquee</a></code> elements:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-marquee-onbounce title=handler-marquee-onbounce><code>onbounce</code></dfn> <td> <code title=event-bounce>bounce</code>
- <tr><td><dfn id=handler-marquee-onfinish title=handler-marquee-onfinish><code>onfinish</code></dfn> <td> <code title=event-finish>finish</code>
- <tr><td><dfn id=handler-marquee-onstart title=handler-marquee-onstart><code>onstart</code></dfn> <td> <code title=event-start>start</code>
+ <tbody><tr><td><dfn id=handler-marquee-onbounce title=handler-marquee-onbounce><code>onbounce</code></dfn> <td> <code title=event-marquee-bounce>bounce</code>
+ <tr><td><dfn id=handler-marquee-onfinish title=handler-marquee-onfinish><code>onfinish</code></dfn> <td> <code title=event-marquee-finish>finish</code>
+ <tr><td><dfn id=handler-marquee-onstart title=handler-marquee-onstart><code>onstart</code></dfn> <td> <code title=event-marquee-start>start</code>
</table><hr><p>The <dfn id=dom-marquee-behavior title=dom-marquee-behavior><code>behavior</code></dfn>, <dfn id=dom-marquee-direction title=dom-marquee-direction><code>direction</code></dfn>, <dfn id=dom-marquee-height title=dom-marquee-height><code>height</code></dfn>, <dfn id=dom-marquee-hspace title=dom-marquee-hspace><code>hspace</code></dfn>, <dfn id=dom-marquee-vspace title=dom-marquee-vspace><code>vspace</code></dfn>, and <dfn id=dom-marquee-width title=dom-marquee-width><code>width</code></dfn> IDL attributes must <a href=#reflect>reflect</a> the
respective content attributes of the same name.</p>
@@ -97099,7 +97151,7 @@
<dd>
- <p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#frame>frame</a></code> element.</p>
+ <p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#frame>frame</a></code> element.</p>
</dd>
@@ -97149,7 +97201,7 @@
<p>When a <code><a href=#document>Document</a></code> in a <code><a href=#frame>frame</a></code> is marked as <a href=#completely-loaded>completely
loaded</a>, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-load>load</code> at the <code><a href=#frame>frame</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#frame>frame</a></code> element.</p>
<p>The <a href=#task-source>task source</a> for the <a href=#concept-task title=concept-task>tasks</a> above is the
<a href=#dom-manipulation-task-source>DOM manipulation task source</a>.</p>
@@ -100929,27 +100981,27 @@
<th> Value
<tbody><tr><th id=ix-handler-onabort> <code title="">onabort</code>
<td> <a href=#handler-onabort title=handler-onabort>HTML elements</a>
- <td> <code title=event-abort>abort</code> event handler
+ <td> <code title=event-abort><a href=#event-abort>abort</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onafterprint> <code title="">onafterprint</code>
<td> <code title=handler-window-onafterprint><a href=#handler-window-onafterprint>body</a></code>
- <td> <code title=event-afterprint>afterprint</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onbeforeprint> <code title="">onbeforeprint</code>
<td> <code title=handler-window-onbeforeprint><a href=#handler-window-onbeforeprint>body</a></code>
- <td> <code title=event-beforeprint>beforeprint</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onbeforeunload> <code title="">onbeforeunload</code>
<td> <code title=handler-window-onbeforeunload><a href=#handler-window-onbeforeunload>body</a></code>
- <td> <code title=event-beforeunload>beforeunload</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onblur> <code title="">onblur</code>
<td> <a href=#handler-onblur title=handler-onblur>HTML elements</a>
- <td> <code title=event-blur>blur</code> event handler
+ <td> <code title=event-blur><a href=#event-blur>blur</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oncancel> <code title="">oncancel</code>
@@ -100969,7 +101021,7 @@
<tr><th id=ix-handler-onchange> <code title="">onchange</code>
<td> <a href=#handler-onchange title=handler-onchange>HTML elements</a>
- <td> <code title=event-change>change</code> event handler
+ <td> <code title=event-change><a href=#event-change>change</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onclick> <code title="">onclick</code>
@@ -100984,57 +101036,57 @@
<tr><th id=ix-handler-oncontextmenu> <code title="">oncontextmenu</code>
<td> <a href=#handler-oncontextmenu title=handler-oncontextmenu>HTML elements</a>
- <td> <code title=event-contextmenu>contextmenu</code> event handler
+ <td> <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oncuechange> <code title="">oncuechange</code>
<td> <a href=#handler-oncuechange title=handler-oncuechange>HTML elements</a>
- <td> <code title=event-cuechange>cuechange</code> event handler
+ <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondblclick> <code title="">ondblclick</code>
<td> <a href=#handler-ondblclick title=handler-ondblclick>HTML elements</a>
- <td> <code title=event-dblclick>dblclick</code> event handler
+ <td> <code title=event-dblclick><a href=#event-dblclick>dblclick</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondrag> <code title="">ondrag</code>
<td> <a href=#handler-ondrag title=handler-ondrag>HTML elements</a>
- <td> <code title=event-drag><a href=#event-drag>drag</a></code> event handler
+ <td> <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragend> <code title="">ondragend</code>
<td> <a href=#handler-ondragend title=handler-ondragend>HTML elements</a>
- <td> <code title=event-dragend><a href=#event-dragend>dragend</a></code> event handler
+ <td> <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragenter> <code title="">ondragenter</code>
<td> <a href=#handler-ondragenter title=handler-ondragenter>HTML elements</a>
- <td> <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> event handler
+ <td> <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragexit> <code title="">ondragexit</code>
<td> <a href=#handler-ondragexit title=handler-ondragexit>HTML elements</a>
- <td> <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code> event handler
+ <td> <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragleave> <code title="">ondragleave</code>
<td> <a href=#handler-ondragleave title=handler-ondragleave>HTML elements</a>
- <td> <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> event handler
+ <td> <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragover> <code title="">ondragover</code>
<td> <a href=#handler-ondragover title=handler-ondragover>HTML elements</a>
- <td> <code title=event-dragover><a href=#event-dragover>dragover</a></code> event handler
+ <td> <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragstart> <code title="">ondragstart</code>
<td> <a href=#handler-ondragstart title=handler-ondragstart>HTML elements</a>
- <td> <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event handler
+ <td> <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondrop> <code title="">ondrop</code>
<td> <a href=#handler-ondrop title=handler-ondrop>HTML elements</a>
- <td> <code title=event-drop><a href=#event-drop>drop</a></code> event handler
+ <td> <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondurationchange> <code title="">ondurationchange</code>
@@ -101054,12 +101106,12 @@
<tr><th id=ix-handler-onerror> <code title="">onerror</code>
<td> <a href=#handler-onerror title=handler-onerror>HTML elements</a>
- <td> <code title=event-error>error</code> event handler
+ <td> <code title=event-error><a href=#event-error>error</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onfocus> <code title="">onfocus</code>
<td> <a href=#handler-onfocus title=handler-onfocus>HTML elements</a>
- <td> <code title=event-focus>focus</code> event handler
+ <td> <code title=event-focus><a href=#event-focus>focus</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onhashchange> <code title="">onhashchange</code>
@@ -101069,32 +101121,32 @@
<tr><th id=ix-handler-oninput> <code title="">oninput</code>
<td> <a href=#handler-oninput title=handler-oninput>HTML elements</a>
- <td> <code title=event-input>input</code> event handler
+ <td> <code title=event-input><a href=#event-input>input</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oninvalid> <code title="">oninvalid</code>
<td> <a href=#handler-oninvalid title=handler-oninvalid>HTML elements</a>
- <td> <code title=event-invalid>invalid</code> event handler
+ <td> <code title=event-invalid><a href=#event-invalid>invalid</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeydown> <code title="">onkeydown</code>
<td> <a href=#handler-onkeydown title=handler-onkeydown>HTML elements</a>
- <td> <code title=event-keydown>keydown</code> event handler
+ <td> <code title=event-keydown><a href=#event-keydown>keydown</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeypress> <code title="">onkeypress</code>
<td> <a href=#handler-onkeypress title=handler-onkeypress>HTML elements</a>
- <td> <code title=event-keypress>keypress</code> event handler
+ <td> <code title=event-keypress><a href=#event-keypress>keypress</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeyup> <code title="">onkeyup</code>
<td> <a href=#handler-onkeyup title=handler-onkeyup>HTML elements</a>
- <td> <code title=event-keyup>keyup</code> event handler
+ <td> <code title=event-keyup><a href=#event-keyup>keyup</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onload> <code title="">onload</code>
<td> <a href=#handler-onload title=handler-onload>HTML elements</a>
- <td> <code title=event-load>load</code> event handler
+ <td> <code title=event-load><a href=#event-load>load</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onloadeddata> <code title="">onloadeddata</code>
@@ -101119,42 +101171,42 @@
<tr><th id=ix-handler-onmousedown> <code title="">onmousedown</code>
<td> <a href=#handler-onmousedown title=handler-onmousedown>HTML elements</a>
- <td> <code title=event-mousedown>mousedown</code> event handler
+ <td> <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseenter> <code title="">onmouseenter</code>
<td> <a href=#handler-onmouseenter title=handler-onmouseenter>HTML elements</a>
- <td> <code title=event-mouseenter>mouseenter</code> event handler
+ <td> <code title=event-mouseenter><a href=#event-mouseenter>mouseenter</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseleave> <code title="">onmouseleave</code>
<td> <a href=#handler-onmouseleave title=handler-onmouseleave>HTML elements</a>
- <td> <code title=event-mouseleave>mouseleave</code> event handler
+ <td> <code title=event-mouseleave><a href=#event-mouseleave>mouseleave</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmousemove> <code title="">onmousemove</code>
<td> <a href=#handler-onmousemove title=handler-onmousemove>HTML elements</a>
- <td> <code title=event-mousemove>mousemove</code> event handler
+ <td> <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseout> <code title="">onmouseout</code>
<td> <a href=#handler-onmouseout title=handler-onmouseout>HTML elements</a>
- <td> <code title=event-mouseout>mouseout</code> event handler
+ <td> <code title=event-mouseout><a href=#event-mouseout>mouseout</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseover> <code title="">onmouseover</code>
<td> <a href=#handler-onmouseover title=handler-onmouseover>HTML elements</a>
- <td> <code title=event-mouseover>mouseover</code> event handler
+ <td> <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseup> <code title="">onmouseup</code>
<td> <a href=#handler-onmouseup title=handler-onmouseup>HTML elements</a>
- <td> <code title=event-mouseup>mouseup</code> event handler
+ <td> <code title=event-mouseup><a href=#event-mouseup>mouseup</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmousewheel> <code title="">onmousewheel</code>
<td> <a href=#handler-onmousewheel title=handler-onmousewheel>HTML elements</a>
- <td> <code title=event-mousewheel>mousewheel</code> event handler
+ <td> <code title=event-mousewheel><a href=#event-mousewheel>mousewheel</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onoffline> <code title="">onoffline</code>
@@ -101209,17 +101261,17 @@
<tr><th id=ix-handler-onreset> <code title="">onreset</code>
<td> <a href=#handler-onreset title=handler-onreset>HTML elements</a>
- <td> <code title=event-reset>reset</code> event handler
+ <td> <code title=event-reset><a href=#event-reset>reset</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onresize> <code title="">onresize</code>
<td> <a href=#handler-onresize title=handler-onresize>HTML elements</a>
- <td> <code title=event-resize>resize</code> event handler
+ <td> <code title=event-resize><a href=#event-resize>resize</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onscroll> <code title="">onscroll</code>
<td> <a href=#handler-onscroll title=handler-onscroll>HTML elements</a>
- <td> <code title=event-scroll>scroll</code> event handler
+ <td> <code title=event-scroll><a href=#event-scroll>scroll</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onseeked> <code title="">onseeked</code>
@@ -101234,17 +101286,17 @@
<tr><th id=ix-handler-onselect> <code title="">onselect</code>
<td> <a href=#handler-onselect title=handler-onselect>HTML elements</a>
- <td> <code title=event-select>select</code> event handler
+ <td> <code title=event-select><a href=#event-select>select</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onshow> <code title="">onshow</code>
<td> <a href=#handler-onshow title=handler-onshow>HTML elements</a>
- <td> <code title=event-show>show</code> event handler
+ <td> <code title=event-show><a href=#event-show>show</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onsort> <code title="">onsort</code>
<td> <a href=#handler-onsort title=handler-onsort>HTML elements</a>
- <td> <code title=event-sort>sort</code> event handler
+ <td> <code title=event-sort><a href=#event-sort>sort</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onstalled> <code title="">onstalled</code>
@@ -101259,7 +101311,7 @@
<tr><th id=ix-handler-onsubmit> <code title="">onsubmit</code>
<td> <a href=#handler-onsubmit title=handler-onsubmit>HTML elements</a>
- <td> <code title=event-submit>submit</code> event handler
+ <td> <code title=event-submit><a href=#event-submit>submit</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onsuspend> <code title="">onsuspend</code>
@@ -101274,12 +101326,12 @@
<tr><th id=ix-handler-ontoggle> <code title="">ontoggle</code>
<td> <a href=#handler-ontoggle title=handler-ontoggle>HTML elements</a>
- <td> <code title=event-toggle>toggle</code> event handler
+ <td> <code title=event-toggle><a href=#event-toggle>toggle</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onunload> <code title="">onunload</code>
<td> <code title=handler-window-onunload><a href=#handler-window-onunload>body</a></code>
- <td> <code title=event-unload>unload</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-unload><a href=#event-unload>unload</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onvolumechange> <code title="">onvolumechange</code>
@@ -101834,8 +101886,217 @@
</ul>
+ <h3 class=no-num id=events-0>Events</h3>
+ <p><i>This section is non-normative.</i></p>
+ <table><caption>List of events</caption>
+ <thead><tr><th> Event
+ <th> Interface
+ <th> Interesting targets
+ <th> Description
+ <tbody><tr><!-- abort --><td> <dfn id=event-abort title=event-abort><code>abort</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the download was aborted by the user
+
+ <tr><!-- DOMContentLoaded --><td> <dfn id=event-domcontentloaded title=event-DOMContentLoaded><code>DOMContentLoaded</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#document>Document</a></code>
+ <td> Fired at the <code><a href=#document>Document</a></code> once the parser has finished
+
+ <tr><!-- afterprint --><td> <dfn id=event-afterprint title=event-afterprint><code>afterprint</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> after printing
+
+ <tr><!-- afterscriptexecute --><td> <dfn id=event-afterscriptexecute title=event-afterscriptexecute><code>afterscriptexecute</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-script-element>script</a></code> elements
+ <td> Fired at <code><a href=#the-script-element>script</a></code> elements after the script runs (just before the corresponding <code title=event-load><a href=#event-load>load</a></code> event)
+
+ <tr><!-- beforeprint --><td> <dfn id=event-beforeprint title=event-beforeprint><code>beforeprint</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> before printing
+
+ <tr><!-- beforescriptexecute --><td> <dfn id=event-beforescriptexecute title=event-beforescriptexecute><code>beforescriptexecute</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-script-element>script</a></code> elements
+ <td> Fired at <code><a href=#the-script-element>script</a></code> elements just before the script runs; canceling the event cancels the running of the script
+
+ <tr><!-- beforeunload --><td> <dfn id=event-beforeunload title=event-beforeunload><code>beforeunload</code></dfn>
+ <td> <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page is about to be unloaded, in case the page would like to show a warning prompt
+
+ <tr><!-- blur --><td> <dfn id=event-blur title=event-blur><code>blur</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at nodes losing focus <!-- XXX bug 23475 -->
+
+ <tr><!-- cancel --><td> <dfn id=event-cancel title=event-cancel><code>cancel</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-dialog-element>dialog</a></code> elements
+ <td> Fired at <code><a href=#the-dialog-element>dialog</a></code> elements when they are canceled by the user (e.g. by pressing the Escape key)
+
+ <tr><!-- change --><td> <dfn id=event-change title=event-change><code>change</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls when the user commits a value change (see also the <code title=event-input-change><a href=#event-input-change>change</a></code> event of <code><a href=#the-input-element>input</a></code> elements)
+
+ <tr><!-- click --><td> <code title=event-click><a href=#event-click>click</a></code>
+ <td> <code><a href=#mouseevent>MouseEvent</a></code>
+ <td> Elements
+ <td> Normally a mouse event; also synthetically fired at an element before its <a href=#activation-behavior>activation behavior</a> is run, when an element is activated from a non-pointer input device (e.g. a keyboard)
+
+ <tr><!-- close --><td> <dfn id=event-close title=event-close><code>close</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-dialog-element>dialog</a></code> elements, <code><a href=#websocket>WebSocket</a></code>
+ <td> Fired at <code><a href=#the-dialog-element>dialog</a></code> elments when they are closed, and at <code><a href=#websocket>WebSocket</a></code> elements when the connection is terminated
+
+ <tr><!-- connnect --><td> <dfn id=event-workerglobalscope-connect title=event-WorkerGlobalScope-connect><code>connnect</code></dfn>
+ <td> <code><a href=#messageevent>MessageEvent</a></code>
+ <td> <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
+ <td> Fired at a shared worker's global scope when a new client connects
+
+ <tr><!-- contextmenu --><td> <dfn id=event-contextmenu title=event-contextmenu><code>contextmenu</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Elements
+ <td> Fired at elements when the user requests their context menu
+
+ <tr><!-- error --><td> <dfn id=event-error title=event-error><code>error</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects, <code><a href=#worker>Worker</a></code> objects, elements, networking-related objects
+ <td> Fired when unexpected errors occur (e.g. networking errors, script errors, decoding errors)
+
+ <tr><!-- focus --><td> <dfn id=event-focus title=event-focus><code>focus</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at nodes gaining focus <!-- XXX bug 23475 -->
+
+ <tr><!-- hashchange --><td> <dfn id=event-hashchange title=event-hashchange><code>hashchange</code></dfn>
+ <td> <code><a href=#hashchangeevent>HashChangeEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the fragment identifier part of <a href="#the-document's-address">the document's address</a> changes
+
+ <tr><!-- input --><td> <dfn id=event-input title=event-input><code>input</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls when the user changes the value (see also the <code title=event-input-change><a href=#event-input-change>change</a></code> event of <code><a href=#the-input-element>input</a></code> elements)
+
+ <tr><!-- invalid --><td> <dfn id=event-invalid title=event-invalid><code>invalid</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls during form validation if they do not satisfy their constraints
+
+ <tr><!-- load --><td> <dfn id=event-load title=event-load><code>load</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at the <code><a href=#window>Window</a></code> when the document has finished loading; fired at an element containing a resource (e.g. <code><a href=#the-img-element>img</a></code>, <code><a href=#the-embed-element>embed</a></code>) when its resource has finished loading
+
+ <tr><!-- loadend --><td> <dfn id=event-loadend title=event-loadend><code>loadend</code></dfn>
+ <td> <code><a href=#event>Event</a></code> or <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements after a successful load (see also <span title=event-media-loadend>media element events</span>)
+
+ <tr><!-- loadstart --><td> <dfn id=event-loadstart title=event-loadstart><code>loadstart</code></dfn>
+ <td> <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements when a load begins (see also <a href=#event-media-loadstart title=event-media-loadstart>media element events</a>)
+
+ <tr><!-- message --><td> <dfn id=event-message title=event-message><code>message</code></dfn>
+ <td> <code><a href=#messageevent>MessageEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>, <code><a href=#eventsource>EventSource</a></code>, <code><a href=#websocket>WebSocket</a></code>, <code><a href=#messageport>MessagePort</a></code>, <code><a href=#broadcastchannel>BroadcastChannel</a></code>, <code><a href=#dedicatedworkerglobalscope>DedicatedWorkerGlobalScope</a></code>, <code><a href=#worker>Worker</a></code>
+ <td> Fired at an object when it receives a message
+
+ <tr><!-- offline --><td> <dfn id=event-offline title=event-offline><code>offline</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections fails
+
+ <tr><!-- online --><td> <dfn id=event-online title=event-online><code>online</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections returns
+
+ <tr><!-- open --><td> <dfn id=event-open title=event-open><code>open</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#eventsource>EventSource</a></code>, <code><a href=#websocket>WebSocket</a></code>
+ <td> Fired at networking-related objects when a connection is established
+
+ <tr><!-- pagehide --><td> <dfn id=event-pagehide title=event-pagehide><code>pagehide</code></dfn>
+ <td> <code><a href=#pagetransitionevent>PageTransitionEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page's entry in the <a href=#session-history>session history</a> stops being the <a href=#current-entry>current entry</a>
+
+ <tr><!-- pageshow --><td> <dfn id=event-pageshow title=event-pageshow><code>pageshow</code></dfn>
+ <td> <code><a href=#pagetransitionevent>PageTransitionEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page's entry in the <a href=#session-history>session history</a> becomes the <a href=#current-entry>current entry</a>
+
+ <tr><!-- popstate --><td> <dfn id=event-popstate title=event-popstate><code>popstate</code></dfn>
+ <td> <code><a href=#popstateevent>PopStateEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the user navigates the <a href=#session-history>session history</a>
+
+ <tr><!-- progress --><td> <dfn id=event-progress title=event-progress><code>progress</code></dfn>
+ <td> <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements during a <a href=#cors-same-origin>CORS-same-origin</a> image load (see also <a href=#event-media-progress title=event-media-progress>media element events</a>)
+
+ <tr><!-- readystatechange --><td> <dfn id=event-readystatechange title=event-readystatechange><code>readystatechange</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#document>Document</a></code>
+ <td> Fired at the <code><a href=#document>Document</a></code> when it finishes parsing and again when all its subresources have finished loading
+
+ <tr><!-- reset --><td> <dfn id=event-reset title=event-reset><code>reset</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-form-element>form</a></code> elements
+ <td> Fired at a <code><a href=#the-form-element>form</a></code> element when it is <a href=#concept-form-reset title=concept-form-reset>reset</a>
+
+ <tr><!-- select --><td> <dfn id=event-select title=event-select><code>select</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at form controls when an API adjusts the text selection
+
+ <tr><!-- show --><td> <dfn id=event-show title=event-show><code>show</code></dfn>
+ <td> <code><a href=#relatedevent>RelatedEvent</a></code>
+ <td> <code><a href=#the-menu-element>menu</a></code> elements
+ <td> Fired at a <code><a href=#the-menu-element>menu</a></code> element when it is shown as a context menu
+
+ <tr><!-- sort --><td> <dfn id=event-sort title=event-sort><code>sort</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-table-element>table</a></code> elements
+ <td> Fired at <code><a href=#the-table-element>table</a></code> elements before it is sorted; canceling the event cancels the sorting of the table
+
+ <tr><!-- storage --><td> <dfn id=event-storage title=event-storage><code>storage</code></dfn>
+ <td> <code><a href=#storageevent>StorageEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at <code><a href=#window>Window</a></code> event when the corresponding <code title=dom-localStorage><a href=#dom-localstorage>localStorage</a></code> or <code title=dom-sessionStorage><a href=#dom-sessionstorage>sessionStorage</a></code> storage areas change
+
+ <tr><!-- submit --><td> <dfn id=event-submit title=event-submit><code>submit</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-form-element>form</a></code> elements
+ <td> Fired at a <code><a href=#the-form-element>form</a></code> element when it is <a href=#concept-form-submit title=concept-form-submit>submitted</a>
+
+ <tr><!-- toggle --><td> <dfn id=event-toggle title=event-toggle><code>toggle</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-details-element>details</a></code> element
+ <td> Fired at <code><a href=#the-details-element>details</a></code> elements when they open or close
+
+ <tr><!-- unload --><td> <dfn id=event-unload title=event-unload><code>unload</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> object when the page is going away
+
+ </table><!--CLEANUP--><p class=note>See also <a href=#mediaevents>media element
+ events</a>, <a href=#appcacheevents>application cache events</a>,
+ and <a href=#dndevents>drag-and-drop events</a>.</p>
+
+
+
+
<h2 class=no-num id=references>References</h2><!--REFS-->
<p>All references are normative unless marked "Non-normative".</p>
Modified: index
===================================================================
--- index 2014-01-08 00:24:35 UTC (rev 8384)
+++ index 2014-01-08 23:55:07 UTC (rev 8385)
@@ -638,10 +638,10 @@
<li><a href=#guidelines-for-exposing-cues-in-various-formats-as-text-track-cues><span class=secno>4.7.10.12.4 </span>Guidelines for exposing cues in various formats as text track cues</a></li>
<li><a href=#text-track-api><span class=secno>4.7.10.12.5 </span>Text track API</a></li>
<li><a href=#text-tracks-describing-chapters><span class=secno>4.7.10.12.6 </span>Text tracks describing chapters</a></li>
- <li><a href=#cue-events><span class=secno>4.7.10.12.7 </span>Event definitions</a></ol></li>
+ <li><a href=#cue-events><span class=secno>4.7.10.12.7 </span>Event handlers for objects of the text track APIs</a></ol></li>
<li><a href=#user-interface><span class=secno>4.7.10.13 </span>User interface</a></li>
<li><a href=#time-ranges><span class=secno>4.7.10.14 </span>Time ranges</a></li>
- <li><a href=#event-definitions><span class=secno>4.7.10.15 </span>Event definitions</a></li>
+ <li><a href=#the-trackevent-interface><span class=secno>4.7.10.15 </span>The <code>TrackEvent</code> interface</a></li>
<li><a href=#mediaevents><span class=secno>4.7.10.16 </span>Event summary</a></li>
<li><a href=#security-and-privacy-considerations><span class=secno>4.7.10.17 </span>Security and privacy considerations</a></li>
<li><a href=#best-practices-for-authors-using-media-elements><span class=secno>4.7.10.18 </span>Best practices for authors using media elements</a></li>
@@ -819,7 +819,7 @@
<ol>
<li><a href=#declaring-a-context-menu><span class=secno>4.11.5.1 </span>Declaring a context menu</a></li>
<li><a href=#processing-model-2><span class=secno>4.11.5.2 </span>Processing model</a></li>
- <li><a href=#event-definitions-0><span class=secno>4.11.5.3 </span>Event definitions</a></ol></li>
+ <li><a href=#the-relatedevent-interfaces><span class=secno>4.11.5.3 </span>The <code>RelatedEvent</code> interfaces</a></ol></li>
<li><a href=#commands><span class=secno>4.11.6 </span>Commands</a>
<ol>
<li><a href=#facets-0><span class=secno>4.11.6.1 </span>Facets</a></li>
@@ -980,10 +980,12 @@
<li><a href=#scroll-to-fragid><span class=secno>6.6.9 </span>Navigating to a fragment identifier</a></li>
<li><a href=#history-traversal><span class=secno>6.6.10 </span>History traversal</a>
<ol>
- <li><a href=#event-definitions-1><span class=secno>6.6.10.1 </span>Event definitions</a></ol></li>
+ <li><a href=#the-popstateevent-interface><span class=secno>6.6.10.1 </span>The <code>PopStateEvent</code> interface</a></li>
+ <li><a href=#the-hashchangeevent-interface><span class=secno>6.6.10.2 </span>The <code>HashChangeEvent</code> interface</a></li>
+ <li><a href=#the-pagetransitionevent-interface><span class=secno>6.6.10.3 </span>The <code>PageTransitionEvent</code> interface</a></ol></li>
<li><a href=#unloading-documents><span class=secno>6.6.11 </span>Unloading documents</a>
<ol>
- <li><a href=#event-definition><span class=secno>6.6.11.1 </span>Event definition</a></ol></li>
+ <li><a href=#the-beforeunloadevent-interface><span class=secno>6.6.11.1 </span>The <code>BeforeUnloadEvent</code> interface</a></ol></li>
<li><a href=#aborting-a-document-load><span class=secno>6.6.12 </span>Aborting a document load</a></ol></li>
<li><a href=#offline><span class=secno>6.7 </span>Offline Web applications</a>
<ol>
@@ -1102,7 +1104,7 @@
<li><a href=#security-risks-in-the-drag-and-drop-model><span class=secno>8.7.9 </span>Security risks in the drag-and-drop model</a></ol></ol></li>
<li><a href=#comms><span class=secno>9 </span>Communication</a>
<ol>
- <li><a href=#event-definitions-2><span class=secno>9.1 </span>Event definitions</a></li>
+ <li><a href=#the-messageevent-interfaces><span class=secno>9.1 </span>The <code>MessageEvent</code> interfaces</a></li>
<li><a href=#server-sent-events><span class=secno>9.2 </span>Server-sent events</a>
<ol>
<li><a href=#server-sent-events-intro><span class=secno>9.2.1 </span>Introduction</a></li>
@@ -1125,7 +1127,7 @@
<li><a href=#feedback-from-the-protocol><span class=secno>9.3.3 </span>Feedback from the protocol</a></li>
<li><a href=#ping-and-pong-frames><span class=secno>9.3.4 </span>Ping and Pong frames</a></li>
<li><a href=#parsing-websocket-urls><span class=secno>9.3.5 </span>Parsing WebSocket URLs</a></li>
- <li><a href=#event-definitions-3><span class=secno>9.3.6 </span>Event definitions</a></li>
+ <li><a href=#the-closeevent-interfaces><span class=secno>9.3.6 </span>The <code>CloseEvent</code> interfaces</a></li>
<li><a href=#garbage-collection-1><span class=secno>9.3.7 </span>Garbage collection</a></ol></li>
<li><a href=#web-messaging><span class=secno>9.4 </span>Cross-document messaging</a>
<ol>
@@ -1197,7 +1199,7 @@
<li><a href=#the-localstorage-attribute><span class=secno>11.2.3 </span>The <code title=dom-localStorage>localStorage</code> attribute</a></li>
<li><a href=#the-storage-event><span class=secno>11.2.4 </span>The <code title=event-storage>storage</code> event</a>
<ol>
- <li><a href=#event-definition-0><span class=secno>11.2.4.1 </span>Event definition</a></ol></li>
+ <li><a href=#the-storageevent-interface><span class=secno>11.2.4.1 </span>The <code>StorageEvent</code> interface</a></ol></li>
<li><a href=#threads><span class=secno>11.2.5 </span>Threads</a></ol></li>
<li><a href=#disk-space-0><span class=secno>11.3 </span>Disk space</a></li>
<li><a href=#privacy><span class=secno>11.4 </span>Privacy</a>
@@ -1448,7 +1450,8 @@
<li><a href=#element-content-categories class=no-num>Element content categories</a></li>
<li><a href=#attributes-1 class=no-num>Attributes</a></li>
<li><a href=#element-interfaces class=no-num>Element Interfaces</a></li>
- <li><a href=#all-interfaces class=no-num>All Interfaces</a></ol></li>
+ <li><a href=#all-interfaces class=no-num>All Interfaces</a></li>
+ <li><a href=#events-0 class=no-num>Events</a></ol></li>
<li><a href=#references class=no-num>References</a></li>
<li><a href=#acknowledgments class=no-num>Acknowledgments</a></ol>
<!--end-toc-->
@@ -2278,11 +2281,11 @@
<div class=example>
- <p>One way this could manifest itself is with <code><a href=#the-img-element>img</a></code> elements and the <code title=event-load>load</code> event. The event could fire as soon as the element has been
+ <p>One way this could manifest itself is with <code><a href=#the-img-element>img</a></code> elements and the <code title=event-load><a href=#event-load>load</a></code> event. The event could fire as soon as the element has been
parsed, especially if the image has already been cached (which is common).</p>
<p>Here, the author uses the <code title=handler-onload><a href=#handler-onload>onload</a></code> handler on an
- <code><a href=#the-img-element>img</a></code> element to catch the <code title=event-load>load</code> event:</p>
+ <code><a href=#the-img-element>img</a></code> element to catch the <code title=event-load><a href=#event-load>load</a></code> event:</p>
<pre><img src="games.png" alt="Games" onload="gamesLogoHasLoaded(event)"></pre>
@@ -2298,7 +2301,7 @@
</script></pre>
<p>However, if the author first created the <code><a href=#the-img-element>img</a></code> element and then in a separate
- script added the event listeners, there's a chance that the <code title=event-load>load</code>
+ script added the event listeners, there's a chance that the <code title=event-load><a href=#event-load>load</a></code>
event would be fired in between, leading it to be missed:</p>
<pre class=bad><!-- Do not use this style, it has a race condition! -->
@@ -3786,8 +3789,21 @@
<li>The <dfn id=uievent><code>UIEvent</code></dfn> interface's <dfn id=dom-uievent-detail title=dom-UIEvent-detail><code>detail</code></dfn> attribute</li>
<li><dfn id=event-click title=event-click><code>click</code></dfn> event</li>
+ <li><dfn id=event-dblclick title=event-dblclick><code>dblclick</code></dfn> event</li>
+ <li><dfn id=event-mousedown title=event-mousedown><code>mousedown</code></dfn> event</li>
+ <li><dfn id=event-mouseenter title=event-mouseenter><code>mouseenter</code></dfn> event</li>
+ <li><dfn id=event-mouseleave title=event-mouseleave><code>mouseleave</code></dfn> event</li>
+ <li><dfn id=event-mousemove title=event-mousemove><code>mousemove</code></dfn> event</li>
+ <li><dfn id=event-mouseout title=event-mouseout><code>mouseout</code></dfn> event</li>
+ <li><dfn id=event-mouseover title=event-mouseover><code>mouseover</code></dfn> event</li>
+ <li><dfn id=event-mouseup title=event-mouseup><code>mouseup</code></dfn> event</li>
+ <li><dfn id=event-mousewheel title=event-mousewheel><code>mousewheel</code></dfn> event</li>
- </ul><p>This specification sometimes uses the term <dfn title="">name</dfn> to refer to the event's <code title=dom-event-type>type</code>; as in, "an event named <code title="">click</code>" or "if the event name is <code title="">keypress</code>". The terms "name" and "type" for events
+ <li><dfn id=event-keydown title=event-keydown><code>keydown</code></dfn> event</li>
+ <li><dfn id=event-keyup title=event-keyup><code>keyup</code></dfn> event</li>
+ <li><dfn id=event-keypress title=event-keypress><code>keypress</code></dfn> event</li>
+
+ </ul><!--CLEANUP--><p>This specification sometimes uses the term <dfn title="">name</dfn> to refer to the event's <code title=dom-event-type>type</code>; as in, "an event named <code title="">click</code>" or "if the event name is <code title="">keypress</code>". The terms "name" and "type" for events
are synonymous.</p>
<p>The following features are defined in the DOM Parsing and
@@ -3918,6 +3934,8 @@
described in the CSS <cite>Fonts</cite> and <cite>Font Load Events</cite> specifications, including in particular
<dfn id=fontloader><code>FontLoader</code></dfn>. <a href=#refsCSSFONTS>[CSSFONTS]</a> <a href=#refsCSSFONTLOAD>[CSSFONTLOAD]</a></p>
+ <p>Some CSS specification will one day probably specify the <dfn id=event-resize title=event-resize><code>resize</code></dfn> and <dfn id=event-scroll title=event-scroll><code>scroll</code></dfn> events.</p>
+
</dd>
@@ -8718,11 +8736,12 @@
</dl><div class=impl>
+<!--CLEANUP-->
<p>Each document has a <dfn id=current-document-readiness>current document readiness</dfn>. When a <code><a href=#document>Document</a></code> object
is created, it must have its <a href=#current-document-readiness>current document readiness</a> set to the string "<code title="">loading</code>" if the document is associated with an <a href=#html-parser>HTML parser</a>, an
<a href=#xml-parser>XML parser</a>, or an XSLT processor, and to the string "<code title="">complete</code>"
otherwise. Various algorithms during page loading affect this value. When the value is set, the
- user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-readystatechange title=event-readystatechange><code>readystatechange</code></dfn> at the <code><a href=#document>Document</a></code>
+ user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-readystatechange><a href=#event-readystatechange>readystatechange</a></code> at the <code><a href=#document>Document</a></code>
object.</p>
<p>A <code><a href=#document>Document</a></code> is said to have an <dfn id=active-parser>active parser</dfn> if it is associated with an
@@ -9236,7 +9255,7 @@
nodes and drop the parsed ones, while Firefox would basically abort instead, failing to fire
the 'load' event -->
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load>load</code> at <var title="">document</var>.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at <var title="">document</var>.</li>
</ol></li>
<!--SYNCLOAD
@@ -12624,11 +12643,11 @@
<!-- the next few paragraph are similar to text in the <style> section -->
<p>Once the attempts to obtain the resource and its <a href=#critical-subresources>critical subresources</a> are
complete, the user agent must, if the loads were successful, <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-link-element>link</a></code> element, or, if the resource or one of its <a href=#critical-subresources>critical subresources</a>
failed to completely load for any reason (e.g. DNS error, HTTP 404 response, a connection being
prematurely closed, unsupported Content-Type), <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-link-element>link</a></code> element.
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-link-element>link</a></code> element.
Non-network errors in processing the resource or its subresources (e.g. CSS parse errors, PNG
decoding errors) are not failures for the purposes of this paragraph.</p>
@@ -13874,10 +13893,10 @@
<p>Once the attempts to obtain the style sheet's <a href=#critical-subresources>critical subresources</a>, if any, are
complete, or, if the style sheet has no <a href=#critical-subresources>critical subresources</a>, once the style sheet
has been parsed and processed, the user agent must, if the loads were successful or there were
- none, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-style-element>style</a></code> element, or, if one of the style sheet's
+ none, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-style-element>style</a></code> element, or, if one of the style sheet's
<a href=#critical-subresources>critical subresources</a> failed to completely load for any reason (e.g. DNS error, HTTP
404 response, a connection being prematurely closed, unsupported Content-Type), <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at
the <code><a href=#the-style-element>style</a></code> element. Non-network errors in processing the style sheet or its
subresources (e.g. CSS parse errors, PNG decoding errors) are not failures for the purposes of
this paragraph.</p>
@@ -14127,7 +14146,7 @@
<a href=#event-handlers>event handlers</a> with the same names normally supported by <a href=#html-elements>HTML
elements</a>.</p>
- <p class=example>Thus, for example, a bubbling <code title=event-error>error</code> event
+ <p class=example>Thus, for example, a bubbling <code title=event-error><a href=#event-error>error</a></code> event
dispatched on a child of <a href=#the-body-element-0>the body element</a> of a <code><a href=#document>Document</a></code> would first
trigger the <code title=handler-onerror><a href=#handler-onerror>onerror</a></code> <a href=#event-handler-content-attributes>event handler content
attributes</a> of that element, then that of the root <code><a href=#the-html-element>html</a></code> element, and only
@@ -20994,7 +21013,7 @@
<li><p>If the <a href=#list-of-available-images>list of available images</a> contains an entry for <var title="">key</var>, then set the <code><a href=#the-img-element>img</a></code> element to the <a href=#img-all title=img-all>completely
available</a> state, update the presentation of the image appropriately, <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-img-element>img</a></code> element, and abort these steps.</li>
</ol></li>
@@ -21019,14 +21038,14 @@
<li>
<p>⌛ If <var title="">selected source</var> is null, then set the element to the <a href=#img-error title=img-error>broken</a> state, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-img-element>img</a></code> element, and
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-img-element>img</a></code> element, and
abort these steps.</p>
</li>
<li>
- <p>⌛ <a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-progress-event>fire a progress event</a> named <code title=event-loadstart>loadstart</code> at
+ <p>⌛ <a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-progress-event>fire a progress event</a> named <code title=event-loadstart><a href=#event-loadstart>loadstart</a></code> at
the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21057,7 +21076,7 @@
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>, each <a href=#concept-task title=concept-task>task</a>
that is <a href=#queue-a-task title="queue a task">queued</a> by the <a href=#networking-task-source>networking task source</a>
while the image is being <a href=#fetch title=fetch>fetched</a> must <a href=#fire-a-progress-event>fire a progress
- event</a> named <code title=event-progress>progress</code> at the <code><a href=#the-img-element>img</a></code>
+ event</a> named <code title=event-progress><a href=#event-progress>progress</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
</li>
@@ -21080,10 +21099,10 @@
task">queued</a> by the <a href=#networking-task-source>networking task source</a> while the image is being <a href=#fetch title=fetch>fetched</a> must update the presentation of the image, but as each new body
part comes in, it must replace the previous image. Once one body part has been completely
decoded, the user agent must set the <code><a href=#the-img-element>img</a></code> element to the <a href=#img-all title=img-all>completely available</a> state and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code>
+ a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
- <p class=note>The <code title=event-progress>progress</code> and <code title=event-loadend>loadend</code> events are not fired for
+ <p class=note>The <code title=event-progress><a href=#event-progress>progress</a></code> and <code title=event-loadend><a href=#event-loadend>loadend</a></code> events are not fired for
<code><a href=#multipart/x-mixed-replace>multipart/x-mixed-replace</a></code> image streams.</p>
</dd>
@@ -21117,20 +21136,20 @@
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21148,20 +21167,20 @@
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>load</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
<li>
<p>If the resource is <a href=#cors-same-origin>CORS-same-origin</a>: <a href=#fire-a-progress-event>fire a progress event</a>
- named <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
<p>If the resource is <a href=#cors-cross-origin>CORS-cross-origin</a>: <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-load>loadend</code> at the <code><a href=#the-img-element>img</a></code> element.</p>
+ <code title=event-load><a href=#event-load>loadend</a></code> at the <code><a href=#the-img-element>img</a></code> element.</p>
</li>
@@ -21176,8 +21195,8 @@
<p>Either the image data is corrupted in some fatal way such that the image dimensions cannot
be obtained, or the image data is not in a supported file format; the user agent must set the
<code><a href=#the-img-element>img</a></code> element to the <a href=#img-error title=img-error>broken</a> state, abort the <a href=#fetch title=fetch>fetching</a> algorithm, discarding any pending <a href=#concept-task title=concept-task>tasks</a> generated by that algorithm, and then <a href=#queue-a-task>queue a
- task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <code><a href=#the-img-element>img</a></code> element and then <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-loadend>loadend</code> at the <code><a href=#the-img-element>img</a></code>
+ task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-img-element>img</a></code> element and then <a href=#fire-a-simple-event>fire a simple
+ event</a> named <code title=event-loadend><a href=#event-loadend>loadend</a></code> at the <code><a href=#the-img-element>img</a></code>
element.</p>
</dd>
@@ -22903,7 +22922,7 @@
from a document</a>, the user agent must <a href=#a-browsing-context-is-discarded title="a browsing context is
discarded">discard</a> the <a href=#nested-browsing-context>nested browsing context</a>.</p>
- <p class=note>This happens without any <code title=event-unload>unload</code> events firing
+ <p class=note>This happens without any <code title=event-unload><a href=#event-unload>unload</a></code> events firing
(the <a href=#nested-browsing-context>nested browsing context</a> and its <code><a href=#document>Document</a></code> are <em title="a browsing
context is discarded"><a href=#a-browsing-context-is-discarded>discarded</a></em>, not <em title="unload a document"><a href=#unload-a-document>unloaded</a></em>).</p>
@@ -22999,7 +23018,7 @@
<p>When a <code><a href=#document>Document</a></code> in an <code><a href=#the-iframe-element>iframe</a></code> is marked as <a href=#completely-loaded>completely
loaded</a>, the user agent must synchronously run the <a href=#iframe-load-event-steps>iframe load event steps</a>.</p>
- <p class=note>A <code title=event-load>load</code> event is also fired at the
+ <p class=note>A <code title=event-load><a href=#event-load>load</a></code> event is also fired at the
<code><a href=#the-iframe-element>iframe</a></code> element when it is created if no other data is loaded in it.</p>
<p>Each <code><a href=#document>Document</a></code> has an <dfn id=iframe-load-in-progress>iframe load in progress</dfn> flag and a <dfn id=mute-iframe-load>mute
@@ -23017,7 +23036,7 @@
<li><p>Set <var title="">child document</var>'s <a href=#iframe-load-in-progress>iframe load in progress</a>
flag.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load>load</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
<code><a href=#the-iframe-element>iframe</a></code> element.</li>
<li><p>Unset <var title="">child document</var>'s <a href=#iframe-load-in-progress>iframe load in progress</a>
@@ -23034,7 +23053,7 @@
<a href=#browsing-context>browsing context</a> is in the <a href=#delaying-load-events-mode>delaying <code title=event-load>load</code> events
mode</a>, the <code><a href=#the-iframe-element>iframe</a></code> must <a href=#delay-the-load-event>delay the load event</a> of its document.</p>
- <p class=note>If, during the handling of the <code title=event-load>load</code> event, the
+ <p class=note>If, during the handling of the <code title=event-load><a href=#event-load>load</a></code> event, the
<a href=#browsing-context>browsing context</a> in the <code><a href=#the-iframe-element>iframe</a></code> is again <a href=#navigate title=navigate>navigated</a>, that will further <a href=#delay-the-load-event>delay the load event</a>.</p>
</div>
@@ -23611,7 +23630,7 @@
</li>
<li><p>Once the resource or plugin hass completely loaded, <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the
element.</li>
</ol><p>Whether the resource is fetched successfully or not (e.g. whether the response code was a
@@ -23641,7 +23660,7 @@
element now represents this <a href=#plugin>plugin</a> instance.</p>
<p>Once the plugin is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the element.</p>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</p>
</dd>
@@ -23937,7 +23956,7 @@
<li><p><a href=#resolve-a-url title="resolve a url">Resolve</a> the <a href=#url>URL</a> specified by the <code title=attr-object-data><a href=#attr-object-data>data</a></code> attribute, relative to the element.</li>
- <li><p>If that failed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the element, then jump to the step below labeled
+ <li><p>If that failed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, then jump to the step below labeled
<i>fallback</i>.</li>
<li>
@@ -23967,7 +23986,7 @@
been obtained to begin processing the resource.</li>
<li><p>If the load failed (e.g. there was an HTTP 404 error, there was a DNS error), <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at the element, then jump to
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, then jump to
the step below labeled <i>fallback</i>.</li>
<li id=object-type-detection>
@@ -24234,7 +24253,7 @@
<p>If the <a href=#url>URL</a> of the given resource <em>is</em> <code><a href=#about:blank>about:blank</a></code>, then,
instead, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-load>load</code> at the <code><a href=#the-object-element>object</a></code> element. <span class=note>No <code title=event-load>load</code> event is fired at the
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-object-element>object</a></code> element. <span class=note>No <code title=event-load><a href=#event-load>load</a></code> event is fired at the
<code><a href=#about:blank>about:blank</a></code> document itself.</span></p>
<p>The <code><a href=#the-object-element>object</a></code> element <a href=#represents>represents</a> the <a href=#nested-browsing-context>nested browsing
@@ -24295,7 +24314,7 @@
<!--CLEANUP-->
<p>Abort these steps. Once the resource is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the element.</p>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</p>
</li>
@@ -24306,7 +24325,7 @@
aren't being sandboxed</a> or the <a href=#plugin>plugin</a> can be <a href=#concept-plugin-secure title=concept-plugin-secure>secured</a>, then that <a href=#plugin>plugin</a> <a href=#object-plugin>should be used</a>. If these conditions cannot be met, or if the
<a href=#plugin>plugin</a> reports an error, jump to the step below labeled <i>fallback</i>. Otherwise
abort these steps; once the plugin is completely loaded, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-load>load</code> at the element.</li>
+ a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the element.</li>
<li><p><i>Fallback</i>: The <code><a href=#the-object-element>object</a></code> element <a href=#represents>represents</a> the element's
children, ignoring any leading <code><a href=#the-param-element>param</a></code> element children. This is the element's
@@ -25142,7 +25161,7 @@
<div class=example>
<p>If the author isn't sure if user agents will all be able to render the media resources
- provided, the author can listen to the <code title=event-error>error</code> event on the last
+ provided, the author can listen to the <code title=event-error><a href=#event-error>error</a></code> event on the last
<code><a href=#the-source-element>source</a></code> element and trigger fallback behavior:</p>
<pre><script>
@@ -26066,7 +26085,7 @@
then the load failed.</li>
<li><p><i title="">Failed with elements</i>: <a href=#queue-a-task>Queue a task</a>, using the <a href=#dom-manipulation-task-source>DOM
- manipulation task source</a>, to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <var title="">candidate</var> element.</li>
+ manipulation task source</a>, to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <var title="">candidate</var> element.</li>
<li><p>Asynchronously <a href=#await-a-stable-state>await a stable state</a>. The <a href=#synchronous-section>synchronous section</a>
consists of all the remaining steps of this algorithm until the algorithm says the
@@ -26398,7 +26417,7 @@
<p class=note>A user agent that is attempting to reduce network usage while still fetching
the metadata for each <a href=#media-resource>media resource</a> would also stop buffering at this point,
following <a href=#resourceSuspend>the rules described previously</a>, which involve the
- <code title=dom-media-networkState><a href=#dom-media-networkstate>networkState</a></code> attribute switching to the <code title=dom-media-NETWORK_IDLE><a href=#dom-media-network_idle>NETWORK_IDLE</a></code> value and a <code title=event-suspend>suspend</code> event firing.</p>
+ <code title=dom-media-networkState><a href=#dom-media-networkstate>networkState</a></code> attribute switching to the <code title=dom-media-NETWORK_IDLE><a href=#dom-media-network_idle>NETWORK_IDLE</a></code> value and a <code title=event-media-suspend><a href=#event-media-suspend>suspend</a></code> event firing.</p>
<p class=note>The user agent is <em>required</em> to determine the duration of the
<a href=#media-resource>media resource</a> and go through this step before playing.</p> <!-- actually defined
@@ -27637,16 +27656,16 @@
</ol></li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">missed
- cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-enter>enter</code> for the
+ cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-media-enter><a href=#event-media-enter>enter</a></code> for the
<code><a href=#texttrackcue>TextTrackCue</a></code> object with the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">other
- cues</var> that either has its <a href=#text-track-cue-active-flag>text track cue active flag</a> set or is in <var title="">missed cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-exit>exit</code> for the <code><a href=#texttrackcue>TextTrackCue</a></code> object with the later of the
+ cues</var> that either has its <a href=#text-track-cue-active-flag>text track cue active flag</a> set or is in <var title="">missed cues</var>, <a href=#prepare-an-event>prepare an event</a> named <code title=event-media-exit><a href=#event-media-exit>exit</a></code> for the <code><a href=#texttrackcue>TextTrackCue</a></code> object with the later of the
<a href=#text-track-cue-end-time>text track cue end time</a> and the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li><p>For each <a href=#text-track-cue title="text track cue">text track cue</a> in <var title="">current
cues</var> that does not have its <a href=#text-track-cue-active-flag>text track cue active flag</a> set, <a href=#prepare-an-event>prepare an
- event</a> named <code title=event-enter>enter</code> for the <code><a href=#texttrackcue>TextTrackCue</a></code>
+ event</a> named <code title=event-media-enter><a href=#event-media-enter>enter</a></code> for the <code><a href=#texttrackcue>TextTrackCue</a></code>
object with the <a href=#text-track-cue-start-time>text track cue start time</a>.</li>
<li>
@@ -27659,8 +27678,8 @@
cue">text track cues</a> associated with these <a href=#concept-task title=concept-task>tasks</a>.</p>
<p>Finally, sort <a href=#concept-task title=concept-task>tasks</a> in <var title="">events</var> that have
- the same time and same <a href=#text-track-cue-order>text track cue order</a> by placing <a href=#concept-task title=concept-task>tasks</a> that fire <code title=event-enter>enter</code> events before
- those that fire <code title=event-exit>exit</code> events.</p>
+ the same time and same <a href=#text-track-cue-order>text track cue order</a> by placing <a href=#concept-task title=concept-task>tasks</a> that fire <code title=event-media-enter><a href=#event-media-enter>enter</a></code> events before
+ those that fire <code title=event-media-exit><a href=#event-media-exit>exit</a></code> events.</p>
</li>
@@ -27672,9 +27691,9 @@
tracks</a>, and remove duplicates.</p>
<li><p>For each <a href=#text-track>text track</a> in <var title="">affected tracks</var>, in the list
- order, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-cuechange>cuechange</code> at the <code><a href=#texttrack>TextTrack</a></code> object, and, if the
+ order, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> at the <code><a href=#texttrack>TextTrack</a></code> object, and, if the
<a href=#text-track>text track</a> has a corresponding <code><a href=#the-track-element>track</a></code> element, to then <a href=#fire-a-simple-event>fire a
- simple event</a> named <code title=event-cuechange>cuechange</code> at the
+ simple event</a> named <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> at the
<code><a href=#the-track-element>track</a></code> element as well.</li>
<li><p>Set the <a href=#text-track-cue-active-flag>text track cue active flag</a> of all the <a href=#text-track-cue title="text track
@@ -29792,7 +29811,7 @@
<ol><li><p><a href=#queue-a-task>Queue a task</a> to first change the <a href=#text-track-readiness-state>text track readiness state</a> to
<a href=#text-track-failed-to-load title="text track failed to load">failed to load</a> and then <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#the-track-element>track</a></code>
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-track-element>track</a></code>
element.</li>
<li><p>Wait until the <a href=#text-track-readiness-state>text track readiness state</a> is no longer set to <a href=#text-track-loading title="text track loading">loading</a>.</li>
@@ -29812,11 +29831,11 @@
<li>
- <p>If the file was successfully processed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-track-element>track</a></code> element.</p>
+ <p>If the file was successfully processed, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-track-element>track</a></code> element.</p>
<p>Otherwise, the file was not successfully processed (e.g. the format in question is an XML
format and the file contained a well-formedness error that the XML specification requires be
- detected and reported to the application); <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error>error</code> at the <code><a href=#the-track-element>track</a></code> element.</p>
+ detected and reported to the application); <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#the-track-element>track</a></code> element.</p>
</li>
@@ -30536,7 +30555,7 @@
<div class=impl>
- <h6 id=cue-events><span class=secno>4.7.10.12.7 </span>Event definitions</h6>
+ <h6 id=cue-events><span class=secno>4.7.10.12.7 </span>Event handlers for objects of the text track APIs</h6>
<p>The following are the <a href=#event-handlers>event handlers</a> that (and their corresponding <a href=#event-handler-event-type title="event handler event type">event handler event types</a>) must be supported, as <a href=#event-handler-idl-attributes>event handler IDL
attributes</a>, by all objects implementing the <code><a href=#texttracklist>TextTrackList</a></code> interface:</p>
@@ -30549,13 +30568,13 @@
attributes</a>, by all objects implementing the <code><a href=#texttrack>TextTrack</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-texttrack-oncuechange title=handler-TextTrack-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-cuechange>cuechange</code>
+ <tbody><tr><td><dfn id=handler-texttrack-oncuechange title=handler-TextTrack-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code>
</table><p>The following are the <a href=#event-handlers>event handlers</a> that (and their corresponding <a href=#event-handler-event-type title="event handler event type">event handler event types</a>) must be supported, as <a href=#event-handler-idl-attributes>event handler IDL
attributes</a>, by all objects implementing the <code><a href=#texttrackcue>TextTrackCue</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-texttrackcue-onenter title=handler-TextTrackCue-onenter><code>onenter</code></dfn> <td> <code title=event-enter>enter</code>
- <tr><td><dfn id=handler-texttrackcue-onexit title=handler-TextTrackCue-onexit><code>onexit</code></dfn> <td> <code title=event-exit>exit</code>
+ <tbody><tr><td><dfn id=handler-texttrackcue-onenter title=handler-TextTrackCue-onenter><code>onenter</code></dfn> <td> <code title=event-media-enter><a href=#event-media-enter>enter</a></code>
+ <tr><td><dfn id=handler-texttrackcue-onexit title=handler-TextTrackCue-onexit><code>onexit</code></dfn> <td> <code title=event-media-exit><a href=#event-media-exit>exit</a></code>
</table></div>
@@ -30594,7 +30613,7 @@
<p>If the user agent <a href=#expose-a-user-interface-to-the-user title="expose a user interface to the user">exposes a user interface to
the user</a> by displaying controls over the <a href=#media-element>media element</a>, then the user agent
should suppress any user interaction events while the user agent is interacting with this
- interface. (For example, if the user clicks on a video's playback control, <code title=event-mousedown>mousedown</code> events and so forth would not simultaneously be fired at
+ interface. (For example, if the user clicks on a video's playback control, <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> events and so forth would not simultaneously be fired at
elements on the page.)</p>
<p>Where possible (specifically, for starting, stopping, pausing, and unpausing playback, for
@@ -30860,7 +30879,7 @@
</div>
- <h5 id=event-definitions><span class=secno>4.7.10.15 </span>Event definitions</h5>
+ <h5 id=the-trackevent-interface><span class=secno>4.7.10.15 </span>The <code><a href=#trackevent>TrackEvent</a></code> interface</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#trackeventinit>TrackEventInit</a> eventInitDict)]
interface <dfn id=trackevent>TrackEvent</dfn> : <a href=#event>Event</a> {
@@ -31167,24 +31186,18 @@
<td>The <code><a href=#mediacontroller>MediaController</a></code> is no longer a <a href=#blocked-media-controller>blocked media controller</a>.
- <tr><td><dfn id=event-mediacontroller-ended title=event-MediaController-ended><code>ended</code></dfn>
-
- <td><code><a href=#event>Event</a></code>
-
- <td>The <code><a href=#mediacontroller>MediaController</a></code> has reached the end of all the <a href=#slaved-media-elements>slaved media
- elements</a>.
-
<tr><td><dfn id=event-mediacontroller-waiting title=event-MediaController-waiting><code>waiting</code></dfn>
<td><code><a href=#event>Event</a></code>
<td>The <code><a href=#mediacontroller>MediaController</a></code> is now a <a href=#blocked-media-controller>blocked media controller</a>.
- <tr><td><dfn id=event-mediacontcoller-ended title=event-MediaContcoller-ended><code>ended</code></dfn>
+ <tr><td><dfn id=event-mediacontroller-ended title=event-MediaController-ended><code>ended</code></dfn>
<td><code><a href=#event>Event</a></code>
- <td>All the <a href=#slaved-media-elements>slaved media elements</a> have newly <a href=#ended-playback>ended playback</a>.
+ <td>All the <a href=#slaved-media-elements>slaved media elements</a> have newly <a href=#ended-playback>ended playback</a>; the
+ <code><a href=#mediacontroller>MediaController</a></code> has reached the end of all the <a href=#slaved-media-elements>slaved media elements</a>.
<tbody><tr><td><dfn id=event-mediacontroller-durationchange title=event-MediaController-durationchange><code>durationchange</code></dfn>
@@ -31238,7 +31251,7 @@
<td><code><a href=#event>Event</a></code>
- <td>One or more tracks in the track list has been enabled or disabled.
+ <td>One or more tracks in the track list have been enabled or disabled.
<tr><td><dfn id=event-media-addtrack title=event-media-addtrack><code>addtrack</code></dfn>
@@ -31252,6 +31265,40 @@
<td>A track has been removed from the track list.
+ </table><p>The following event fires on <code><a href=#texttrack>TextTrack</a></code> objects and <code><a href=#the-track-element>track</a></code> elements:</p>
+
+ <table><thead><tr><th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody><tr><td><dfn id=event-media-cuechange title=event-media-cuechange><code>cuechange</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>One or more cues in the track have become active or stopped being active.
+
+ </table><p>The following events fire on <code><a href=#texttrackcue>TextTrackCue</a></code> objects:</p>
+
+ <table><thead><tr><th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody><tr><td><dfn id=event-media-enter title=event-media-enter><code>enter</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>The cure has become active.
+
+ <tr><td><dfn id=event-media-exit title=event-media-exit><code>exit</code></dfn>
+
+ <td><code><a href=#event>Event</a></code>
+
+ <td>The cure has stopped being active.
+
</table><!--ADD-TOPIC:Security--><div class=impl>
<h5 id=security-and-privacy-considerations><span class=secno>4.7.10.17 </span>Security and privacy considerations</h5>
@@ -35891,7 +35938,7 @@
<li><p>Set <var title="">table</var>'s <a href=#currently-sorting-flag>currently-sorting flag</a> to true.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-sort>sort</code> that is
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-sort><a href=#event-sort>sort</a></code> that is
cancelable at <var title="">table</var>.</li>
<li><p>If the event fired in the previous step was canceled, then jump to the step labeled
@@ -35904,7 +35951,7 @@
<p class=note>Even if <var title="">table</var> was a <a href=#sorting-enabled-table-element>sorting-enabled <code>table</code>
element</a> when the algorithm was invoked, the DOM might have been entirely changed by the
- event handlers for the <code title=event-sort>sort</code> event, so this has to be verified at
+ event handlers for the <code title=event-sort><a href=#event-sort>sort</a></code> event, so this has to be verified at
this stage, not earlier.</p>
</li>
@@ -37463,7 +37510,7 @@
<p><button>Submit order</button></p>
</form></pre>
- <p class=note>When a form is submitted, <code title=event-invalid>invalid</code> events are
+ <p class=note>When a form is submitted, <code title=event-invalid><a href=#event-invalid>invalid</a></code> events are
fired at each form control that is invalid, and then at the <code><a href=#the-form-element>form</a></code> element itself. This
can be useful for displaying a summary of the problems with the form, since typically the browser
itself will only report one problem at a time.</p>
@@ -39818,7 +39865,7 @@
"<code title=attr-dir-rtl><a href=#attr-dir-rtl>rtl</a></code>" if the user selected a right-to-left writing
direction.</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element.</li>
</ol></div>
@@ -41873,7 +41920,7 @@
activation steps</a> consist of setting the <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a>
and the element's <code title=dom-input-indeterminate><a href=#dom-input-indeterminate>indeterminate</a></code> IDL attribute back to
the values they had before the <a href=#pre-click-activation-steps>pre-click activation steps</a> were run. The
- <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. --></p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42002,7 +42049,7 @@
</ul><!--CLEANUP--><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, then: The <a href=#pre-click-activation-steps>pre-click
activation steps</a> consist of setting the element's <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a> to true. The <a href=#canceled-activation-steps>canceled activation steps</a>
consist of setting the element's <a href=#concept-fe-checked title=concept-fe-checked>checkedness</a> to false. The
- <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ <a href=#activation-behavior>activation behavior</a> is to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the element and then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. -->.</p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42119,18 +42166,19 @@
<li><p>Wait for the user to have made their selection.</li>
+<!--CLEANUP-->
<li><p><a href=#queue-a-task>Queue a task</a> to first update the element's <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> so that it represents the user's
- selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire a
- simple event</a> that bubbles named <code title=event-change>change</code> at the
+ selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire a
+ simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</li>
- </ol><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, the user agent should allow the
+ </ol><!--CLEANUP--><p>If the element is <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, the user agent should allow the
user to change the files on the list in other ways also, e.g. adding or removing files by
drag-and-drop. When the user does so, the user agent must <a href=#queue-a-task>queue a task</a> to first
update the element's <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> so that
it represents the user's new selection, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire
- a simple event</a> that bubbles named <code title=event-change>change</code> at the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and finally <a href=#fire-a-simple-event>fire
+ a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</p>
<p>If the element is not <i title=concept-fe-mutable><a href=#concept-fe-mutable>mutable</a></i>, it has no <a href=#activation-behavior>activation
@@ -42473,10 +42521,10 @@
<p>The <a href=#concept-task title=concept-task>task</a> that is <a href=#queue-a-task title="queue a task">queued</a> by
the <a href=#networking-task-source>networking task source</a> once the resource has been <a href=#fetch title=fetch>fetched</a>, must, if the download was successful and the image is <i title=input-img-available><a href=#input-img-available>available</a></i>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the <code><a href=#the-input-element>input</a></code> element; and
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-input-element>input</a></code> element; and
otherwise, if the fetching process fails without a response from the remote server, or completes
but the image is not a valid or supported image, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> on the <code><a href=#the-input-element>input</a></code> element.</p>
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> on the <code><a href=#the-input-element>input</a></code> element.</p>
<hr></div>
@@ -43767,13 +43815,13 @@
<h5 id=common-input-element-events><span class=secno>4.10.5.5 </span>Common event behaviors</h5>
- <p>When the <code title=event-input>input</code> and <code title=event-change>change</code>
+ <p>When the <code title=event-input-input><a href=#event-input-input>input</a></code> and <code title=event-input-change><a href=#event-input-change>change</a></code>
events <a href=#concept-input-apply title=concept-input-apply>apply</a> (which is the case for all
<code><a href=#the-input-element>input</a></code> controls other than <a href=#concept-button title=concept-button>buttons</a> and those with
the <code title=attr-input-type><a href=#attr-input-type>type</a></code> attribute in the <a href="#hidden-state-(type=hidden)" title=attr-input-type-hidden>Hidden</a> state), the events are fired to indicate that the
user has interacted with the control. The <dfn id=event-input-input title=event-input-input><code>input</code></dfn>
event fires whenever the user has modified the data of the control. The <dfn id=event-input-change title=event-input-change><code>change</code></dfn> event fires when the value is committed, if
- that makes sense for the control, or else when the control loses focus. In all cases, the <code title=event-input>input</code> event comes before the corresponding <code title=event-change>change</code> event (if any).</p>
+ that makes sense for the control, or else when the control loses focus. In all cases, the <code title=event-input-input><a href=#event-input-input>input</a></code> event comes before the corresponding <code title=event-input-change><a href=#event-input-change>change</a></code> event (if any).</p>
<p>When an <code><a href=#the-input-element>input</a></code> element has a defined <a href=#activation-behavior>activation behavior</a>, the rules
for dispatching these events, if they <a href=#concept-input-apply title=concept-input-apply>apply</a>, are given
@@ -43784,15 +43832,15 @@
which these events <a href=#concept-input-apply title=concept-input-apply>apply</a>, and for which the user
interface involves both interactive manipulation and an explicit commit action, then when the user
changes the element's <a href=#concept-fe-value title=concept-fe-value>value</a>, the user agent must
- <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and any time the user commits
+ <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and any time the user commits
the change, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-change>change</code> at the <code><a href=#the-input-element>input</a></code> element.</p>
+ bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the <code><a href=#the-input-element>input</a></code> element.</p>
<p class=example>An example of a user interface involving both interactive manipulation and a
commit action would be a <a href="#range-state-(type=range)" title=attr-input-type-range>Range</a> controls that use a
slider, when manipulated using a pointing device. While the user is dragging the control's knob,
- <code title=event-input>input</code> events would fire whenever the position changed, whereas
- the <code title=event-change>change</code> event would only fire when the user let go of the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> events would fire whenever the position changed, whereas
+ the <code title=event-input-change><a href=#event-input-change>change</a></code> event would only fire when the user let go of the
knob, committing to a specific value.</p>
<p>For <code><a href=#the-input-element>input</a></code> elements without a defined <a href=#activation-behavior>activation behavior</a>, but to
@@ -43800,8 +43848,8 @@
interface involves an explicit commit action but no intermediate manipulation, then any time the
user commits a change to the element's <a href=#concept-fe-value title=concept-fe-value>value</a>, the user
agent must <a href=#queue-a-task>queue a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, and then <a href=#fire-a-simple-event>fire a
- simple event</a> that bubbles named <code title=event-change>change</code> at the
+ <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, and then <a href=#fire-a-simple-event>fire a
+ simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at the
<code><a href=#the-input-element>input</a></code> element.</p>
<p class=example>An example of a user interface with a commit action would be a <a href="#color-state-(type=color)" title=attr-input-type-color>Color</a> control that consists of a single button that brings
@@ -43819,8 +43867,8 @@
which these events <a href=#concept-input-apply title=concept-input-apply>apply</a>, any time the user causes the
element's <a href=#concept-fe-value title=concept-fe-value>value</a> to change without an explicit commit
action, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element. The
- corresponding <code title=event-change>change</code> event, if any, will be fired when the
+ bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element. The
+ corresponding <code title=event-input-change><a href=#event-input-change>change</a></code> event, if any, will be fired when the
control <a href=#unfocusing-steps title="unfocusing steps">loses focus</a>.</p>
<p class=example>Examples of a user changing the element's <a href=#concept-fe-value title=concept-fe-value>value</a> would include the user typing into a text field, pasting a
@@ -43833,7 +43881,7 @@
of the user changing the element's <a href=#concept-fe-value title=concept-fe-value>value</a> without a commit
step.</p>
- <p>In the case of <a href=#concept-task title=concept-task>tasks</a> that just fire an <code title=event-input>input</code> event, user agents may wait for a suitable break in the user's
+ <p>In the case of <a href=#concept-task title=concept-task>tasks</a> that just fire an <code title=event-input-input><a href=#event-input-input>input</a></code> event, user agents may wait for a suitable break in the user's
interaction before <a href=#queue-a-task title="queue a task">queuing</a> the tasks; for example, a user agent
could wait for the user to have not hit a key for 100ms, so as to only fire the event when the
user pauses, instead of continuously for each keystroke. <!-- similar text is present in the
@@ -43841,8 +43889,8 @@
<p>When the user agent is to change an <code><a href=#the-input-element>input</a></code> element's <a href=#concept-fe-value title=concept-fe-value>value</a> on behalf of the user (e.g. as part of a form prefilling
feature), the user agent must <a href=#queue-a-task>queue a task</a> to first update the <a href=#concept-fe-value title=concept-fe-value>value</a> accordingly, then <a href=#fire-a-simple-event>fire a simple event</a> that
- bubbles named <code title=event-input>input</code> at the <code><a href=#the-input-element>input</a></code> element, then
- <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at
+ bubbles named <code title=event-input-input><a href=#event-input-input>input</a></code> at the <code><a href=#the-input-element>input</a></code> element, then
+ <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input-change><a href=#event-input-change>change</a></code> at
the <code><a href=#the-input-element>input</a></code> element.</p>
<p class=note>These events are not fired in response to changes made to the values of form
@@ -43983,7 +44031,7 @@
<li><p>Let <var title="">menu</var> be the element's <a href=#designated-pop-up-menu>designated pop-up menu</a>, if
any. If there isn't one, then abort these steps.</li>
- <li><p><a href=#concept-event-fire title=concept-event-fire>Fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show>show</code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
+ <li><p><a href=#concept-event-fire title=concept-event-fire>Fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show><a href=#event-show>show</a></code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
interface, with the <code title=dom-RelatedEvent-relatedTarget><a href=#dom-relatedevent-relatedtarget>relatedTarget</a></code> attribute
initialized to the <code><a href=#the-button-element>button</a></code> element. The event must be cancelable. <!-- v2: include
modifier key information --></li>
@@ -44226,8 +44274,8 @@
user agent must <a href=#send-select-update-notifications>send <code>select</code> update notifications</a>.</p>
<p>When the user agent is to <dfn id=send-select-update-notifications>send <code>select</code> update notifications</dfn>, <a href=#queue-a-task>queue
- a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-select-element>select</a></code> element, and then <a href=#fire-a-simple-event>fire a simple
- event</a> that bubbles named <code title=event-change>change</code> at the
+ a task</a> to first <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-select-element>select</a></code> element, and then <a href=#fire-a-simple-event>fire a simple
+ event</a> that bubbles named <code title=event-change><a href=#event-change>change</a></code> at the
<code><a href=#the-select-element>select</a></code> element, using the <a href=#user-interaction-task-source>user interaction task source</a> as the task
source.</p>
@@ -45045,7 +45093,7 @@
<p>When a <code><a href=#the-textarea-element>textarea</a></code> is <a href=#concept-fe-mutable title=concept-fe-mutable>mutable</a>, its <a href=#concept-textarea-raw-value title=concept-textarea-raw-value>raw value</a> should be editable by the user: the user agent
should allow the user to edit, insert, and remove text, and to insert and remove line breaks in
the form of U+000A LINE FEED (LF) characters. Any time the user causes the element's <a href=#concept-textarea-raw-value title=concept-textarea-raw-value>raw value</a> to change, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-textarea-element>textarea</a></code> element. User agents may wait for a
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-textarea-element>textarea</a></code> element. User agents may wait for a
suitable break in the user's interaction before queuing the task; for example, a user agent could
wait for the user to have not hit a key for 100ms, so as to only fire the event when the user
pauses, instead of continuously for each keystroke.</p> <!-- same text is present in the <input>
@@ -45076,7 +45124,7 @@
"<code title=attr-dir-rtl><a href=#attr-dir-rtl>rtl</a></code>" if the user selected a right-to-left writing
direction.</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input>input</code> at the <code><a href=#the-textarea-element>textarea</a></code> element.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-input><a href=#event-input>input</a></code> at the <code><a href=#the-textarea-element>textarea</a></code> element.</li>
</ol></div>
@@ -48378,7 +48426,7 @@
contents of the text field to be fully selected, with the selection direction being none, if the
platform support selections with the direction <i>none</i>, or otherwise <i>forward</i>. The user
agent must then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named
- <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</p>
@@ -48429,7 +48477,7 @@
<a href=#case-sensitive>case-sensitive</a> match for the string "<code title="">backward</code>", <i>forward</i>
if <var title="">direction</var> is a <a href=#case-sensitive>case-sensitive</a> match for the string "<code title="">forward</code>" or if the platform does not support selections with the direction
<i>none</i>, and <i>none</i> otherwise (including if the argument is omitted). The user agent must
- then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</p>
@@ -48547,7 +48595,7 @@
</li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select>select</code> at the element, using the <a href=#user-interaction-task-source>user interaction task
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-select><a href=#event-select>select</a></code> at the element, using the <a href=#user-interaction-task-source>user interaction task
source</a> as the task source.</li>
</ol><p>All elements to which this API <a href=#concept-input-apply title=concept-input-apply>applies</a> have either a
@@ -48723,7 +48771,7 @@
<p>For each element <var title="">field</var> in <var title="">invalid controls</var>, if any,
in <a href=#tree-order>tree order</a>, run the following substeps:</p>
- <ol><li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-invalid>invalid</code> that
+ <ol><li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that
is cancelable at <var title="">field</var>.</li>
<li><p>If the event was not canceled, then add <var title="">field</var> to <var title="">unhandled invalid controls</var>.</li>
@@ -48874,7 +48922,7 @@
<dd>
- <p>Returns true if the element's value has no validity problems; false otherwise. Fires an <code title=event-invalid>invalid</code> event at the element in the latter case.</p>
+ <p>Returns true if the element's value has no validity problems; false otherwise. Fires an <code title=event-invalid><a href=#event-invalid>invalid</a></code> event at the element in the latter case.</p>
</dd>
@@ -48883,7 +48931,7 @@
<dd>
<p>Returns true if the element's value has no validity problems; otherwise, returns false, fires
- an <code title=event-invalid>invalid</code> event at the element, and (if the event isn't
+ an <code title=event-invalid><a href=#event-invalid>invalid</a></code> event at the element, and (if the event isn't
canceled) reports the problem to the user.</p>
</dd>
@@ -48992,13 +49040,13 @@
</dl><p>When the <dfn id=dom-cva-checkvalidity title=dom-cva-checkValidity><code>checkValidity()</code></dfn> method is
invoked, if the element is a <a href=#candidate-for-constraint-validation>candidate for constraint validation</a> and does not <a href=#concept-fv-valid title=concept-fv-valid>satisfy its constraints</a>, the user agent must <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-invalid>invalid</code> that is cancelable (but in this case
+ event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that is cancelable (but in this case
has no default action) at the element and return false. Otherwise, it must only return true
without doing anything else.</p>
<p>When the <dfn id=dom-cva-reportvalidity title=dom-cva-reportValidity><code>reportValidity()</code></dfn> method is
invoked, if the element is a <a href=#candidate-for-constraint-validation>candidate for constraint validation</a> and does not <a href=#concept-fv-valid title=concept-fv-valid>satisfy its constraints</a>, the user agent must: <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-invalid>invalid</code> that is cancelable at the element,
+ event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> that is cancelable at the element,
and if that event is not canceled, report the problems with the constraints of that element to the
user; then, return false. Otherwise, it must only return true without doing anything else. When
reporting the problem with the constraints to the user, the user agent may run the <a href=#focusing-steps>focusing
@@ -49155,12 +49203,12 @@
method</var> flag is not set, and the <var title="">submitter</var> element's <a href=#concept-fs-novalidate title=concept-fs-novalidate>no-validate state</a> is false, then <a href=#interactively-validate-the-constraints>interactively
validate the constraints</a> of <var title="">form</var> and examine the result: if the result
is negative (the constraint validation concluded that there were invalid fields and probably
- informed the user of this) then <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-invalid>invalid</code> at the <var title="">form</var> element and then abort these
+ informed the user of this) then <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-invalid><a href=#event-invalid>invalid</a></code> at the <var title="">form</var> element and then abort these
steps.</li>
<li><p>If the <var title="">submitted from <code title=dom-form-submit><a href=#dom-form-submit>submit()</a></code>
method</var> flag is not set, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles and is
- cancelable named <code title=event-submit>submit</code>, at <var title="">form</var>. If the
+ cancelable named <code title=event-submit><a href=#event-submit>submit</a></code>, at <var title="">form</var>. If the
event's default action is prevented (i.e. if the event is canceled) then abort these steps.
Otherwise, continue (effectively the default action is to perform the submission).</li>
@@ -50042,10 +50090,10 @@
<h4 id=resetting-a-form><span class=secno>4.10.23 </span>Resetting a form</h4>
<p>When a <code><a href=#the-form-element>form</a></code> element <var title="">form</var> is <dfn id=concept-form-reset title=concept-form-reset>reset</dfn>, the user agent must <a href=#fire-a-simple-event>fire a simple event</a> named
- <code title=event-reset>reset</code>, that bubbles and is cancelable, at <var title="">form</var>, and then, if that event is not canceled, must invoke the <a href=#concept-form-reset-control title=concept-form-reset-control>reset algorithm</a> of each <a href=#category-reset title=category-reset>resettable element</a> whose <a href=#form-owner>form owner</a> is <var title="">form</var>.</p>
+ <code title=event-reset><a href=#event-reset>reset</a></code>, that bubbles and is cancelable, at <var title="">form</var>, and then, if that event is not canceled, must invoke the <a href=#concept-form-reset-control title=concept-form-reset-control>reset algorithm</a> of each <a href=#category-reset title=category-reset>resettable element</a> whose <a href=#form-owner>form owner</a> is <var title="">form</var>.</p>
<p>Each <a href=#category-reset title=category-reset>resettable element</a> defines its own <dfn id=concept-form-reset-control title=concept-form-reset-control>reset algorithm</dfn>. Changes made to form controls as part of
- these algorithms do not count as changes caused by the user (and thus, e.g., do not cause <code title=event-input>input</code> events to fire).</p>
+ these algorithms do not count as changes caused by the user (and thus, e.g., do not cause <code title=event-input><a href=#event-input>input</a></code> events to fire).</p>
</div>
@@ -50120,7 +50168,7 @@
</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-toggle>toggle</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-toggle><a href=#event-toggle>toggle</a></code> at the
<code><a href=#the-details-element>details</a></code> element.</li>
</ol><p>The <a href=#task-source>task source</a> for this task must be the <a href=#dom-manipulation-task-source>DOM manipulation task
@@ -50660,8 +50708,8 @@
element in the same <a href=#home-subtree>home subtree</a> whose <code title=attr-menu-type><a href=#attr-menu-type>type</a></code>
attribute is in the <a href=#popup-menu-state title="popup menu state">popup menu</a> state.</p>
- <p class=note>When a user right-clicks on an element with a <code title=attr-contextmenu><a href=#attr-contextmenu>contextmenu</a></code> attribute, the user agent will first fire a <code title=event-contextmenu>contextmenu</code> event at the element, and then, if that event is not
- canceled, a <code title=event-show>show</code> event at the <code><a href=#the-menu-element>menu</a></code> element.</p>
+ <p class=note>When a user right-clicks on an element with a <code title=attr-contextmenu><a href=#attr-contextmenu>contextmenu</a></code> attribute, the user agent will first fire a <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event at the element, and then, if that event is not
+ canceled, a <code title=event-show><a href=#event-show>show</a></code> event at the <code><a href=#the-menu-element>menu</a></code> element.</p>
<div class=example>
@@ -50702,7 +50750,7 @@
<dl class=switch><dt>If the user requested a context menu using a pointing device</dt>
- <dd><p>The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-contextmenu>contextmenu</code>, that bubbles and is cancelable, and that uses the
+ <dd><p>The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code>, that bubbles and is cancelable, and that uses the
<code><a href=#mouseevent>MouseEvent</a></code> interface, at the element for which the menu was requested. The context
information of the event must be initialized to the same values as the last
<code><a href=#mouseevent>MouseEvent</a></code> user interaction event that was fired as part of the gesture that was
@@ -50714,10 +50762,10 @@
event named <code title=event-contextmenu>contextmenu</code></a> that bubbles and is
cancelable at the element for which the menu was requested.</dd>
- </dl><p class=note>Typically, therefore, the firing of the <code title=event-contextmenu>contextmenu</code> event will be the default action of a <code title=mouseup>mouseup</code> or <code title=event-keyup>keyup</code> event. The exact sequence
+ </dl><p class=note>Typically, therefore, the firing of the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event will be the default action of a <code title=mouseup>mouseup</code> or <code title=event-keyup><a href=#event-keyup>keyup</a></code> event. The exact sequence
of events is UA-dependent, as it will vary based on platform conventions.</p>
- <p>The default action of the <code title=event-contextmenu>contextmenu</code> event depends on
+ <p>The default action of the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event depends on
whether or not the element for which the menu was requested has a non-null <a href=#assigned-context-menu>assigned context
menu</a> when the event dispatch has completed, as follows.</p>
@@ -50726,14 +50774,14 @@
one.</p>
<p>Otherwise, let <var title="">subject</var> be the element for which the menu was requested, and
- let <var title="">menu</var> be the <a href=#assigned-context-menu>assigned context menu</a> of <var title="">target</var> immediately after the <code title=event-contextmenu>contextmenu</code>
+ let <var title="">menu</var> be the <a href=#assigned-context-menu>assigned context menu</a> of <var title="">target</var> immediately after the <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code>
event's dispatch has completed. The user agent must <a href=#concept-event-fire title=concept-event-fire>fire</a> a
- <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show>show</code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
+ <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event with the name <code title=event-show><a href=#event-show>show</a></code> at <var title="">menu</var>, using the <code><a href=#relatedevent>RelatedEvent</a></code>
interface, with the <code title=dom-RelatedEvent-relatedTarget><a href=#dom-relatedevent-relatedtarget>relatedTarget</a></code> attribute
initialized to <var title="">subject</var>. The event must be cancelable. <!-- v2: include
modifier key information --></p>
- <p>If <em>this</em> event (the <code title=event-show>show</code> event) is not canceled, then
+ <p>If <em>this</em> event (the <code title=event-show><a href=#event-show>show</a></code> event) is not canceled, then
the user agent must <a href=#construct-and-show-a-menu title="construct and show a menu">construct and show</a> the menu for
<var title="">menu</var> with <var title="">subject</var> as the subject.</p>
@@ -50747,7 +50795,7 @@
<p>User agents may provide means for bypassing the context menu processing model, ensuring that
the user can always access the UA's default context menus. For example, the user agent could
handle right-clicks that have the Shift key depressed in such a way that it does not fire the
- <code title=event-contextmenu>contextmenu</code> event and instead always shows the default
+ <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event and instead always shows the default
context menu.</p>
<hr><p>The <dfn id=dom-contextmenu title=dom-contextMenu><code>contextMenu</code></dfn> IDL attribute must
@@ -50778,7 +50826,7 @@
<p><img src=http://images.whatwg.org/contextmenu-expanded.png alt="This would result in the same basic interface, but with a longer menu; the disclosure triangle having been replaced by items such as 'View Image', 'Copy Image', 'Copy Image Location', and so forth."></div>
- <h5 id=event-definitions-0><span class=secno>4.11.5.3 </span>Event definitions</h5>
+ <h5 id=the-relatedevent-interfaces><span class=secno>4.11.5.3 </span>The <code><a href=#relatedevent>RelatedEvent</a></code> interfaces</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#relatedeventinit>RelatedEventInit</a> eventInitDict)]
interface <dfn id=relatedevent>RelatedEvent</dfn> : <a href=#event>Event</a> {
@@ -50793,7 +50841,7 @@
<dd>
- <p>Returns the other event target involved in this event. For example, when a <code title=event-show>show</code> event fires on a <code><a href=#the-menu-element>menu</a></code> element, the other event
+ <p>Returns the other event target involved in this event. For example, when a <code title=event-show><a href=#event-show>show</a></code> event fires on a <code><a href=#the-menu-element>menu</a></code> element, the other event
target involved in the event would be the element for which the menu is being shown.</p>
</dd>
@@ -51588,15 +51636,15 @@
</ol></li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-close title=event-close><code>close</code></dfn> at <var title="">subject</var>.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-close><a href=#event-close>close</a></code> at <var title="">subject</var>.</li>
</ol><!--TOPIC:DOM APIs--><p>The <dfn id=dom-dialog-returnvalue title=dom-dialog-returnValue><code>returnValue</code></dfn> IDL attribute, on
getting, must return the last value to which it was set. On setting, it must be set to the new
value. When the element is created, it must be set to the empty string.</p>
<!--TOPIC:HTML-->
- <hr><p><strong>Canceling dialogs</strong>: When a <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog
- stack</a> is not empty, user agents may provide a user interface that, upon activation, <a href=#queue-a-task title="queue a task">queues a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-cancel title=event-cancel><code>cancel</code></dfn> that is cancelable at the top <code><a href=#the-dialog-element>dialog</a></code>
+ <hr><!--CLEANUP--><p><strong>Canceling dialogs</strong>: When a <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog
+ stack</a> is not empty, user agents may provide a user interface that, upon activation, <a href=#queue-a-task title="queue a task">queues a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-cancel><a href=#event-cancel>cancel</a></code> that is cancelable at the top <code><a href=#the-dialog-element>dialog</a></code>
element on the <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog stack</a>. The default action of
this event must be to check if that element has an <code title=attr-dialog-open><a href=#attr-dialog-open>open</a></code>
attribute, and if it does, <a href=#close-the-dialog>close the dialog</a> with no return value.</p>
@@ -52230,14 +52278,14 @@
<ol><li><p>Let <var title="">src</var> be the value of the element's <code title=attr-script-src><a href=#attr-script-src>src</a></code> attribute.</li>
<li><p>If <var title="">src</var> is the empty string, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at the element, and abort
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, and abort
these steps.</li>
<li><p><a href=#resolve-a-url title="resolve a url">Resolve</a> <var title="">src</var> relative to the
element.</li>
<li><p>If the previous step failed, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-error>error</code> at the element, and abort these
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element, and abort these
steps.</li>
<li>
@@ -52421,7 +52469,7 @@
<dl class=switch><dt>If the load resulted in an error (for example a DNS error, or an HTTP 404 error)</dt>
<dd><p>Executing the script block must just consist of <a href=#fire-a-simple-event title="fire a simple event">firing
- a simple event</a> named <code title=event-error>error</code> at the element.</dd>
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the element.</dd>
<dt>If the load was successful</dt>
@@ -52510,7 +52558,7 @@
<li>
- <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-beforescriptexecute>beforescriptexecute</code> that bubbles and is cancelable
+ <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-beforescriptexecute><a href=#event-beforescriptexecute>beforescriptexecute</a></code> that bubbles and is cancelable
at the <code><a href=#the-script-element>script</a></code> element.</p>
<p>If the event is canceled, then abort these steps.</p>
@@ -52577,17 +52625,17 @@
<li>
- <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-afterscriptexecute>afterscriptexecute</code> that bubbles (but is not
+ <p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-afterscriptexecute><a href=#event-afterscriptexecute>afterscriptexecute</a></code> that bubbles (but is not
cancelable) at the <code><a href=#the-script-element>script</a></code> element.</p>
</li>
<li>
- <p>If the script is from an external file, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#the-script-element>script</a></code> element.</p>
+ <p>If the script is from an external file, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-script-element>script</a></code> element.</p>
<p>Otherwise, the script is internal; <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
- event</a> named <code title=event-load>load</code> at the <code><a href=#the-script-element>script</a></code>
+ event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#the-script-element>script</a></code>
element.</p>
</li>
@@ -55236,7 +55284,7 @@
attribute's allowed keywords correspond to alignment points in the
font:</p>
- <p><img src=http://images.whatwg.org/baselines.png width=738 alt="The top of the em square is roughly at the top of the glyphs in a font, the hanging baseline is where some glyphs like आ are anchored, the middle is half-way between the top of the em square and the bottom of the em square, the alphabetic baseline is where characters like Á, ÿ, f, and Ω are anchored, the ideographic baseline is where glyphs like 私 and 達 are anchored, and the bottom of the em square is roughly at the bottom of the glyphs in a font. The top and bottom of the bounding box can be far from these baselines, due to glyphs extending far outside the em square." height=300></p>
+ <p><img src=http://images.whatwg.org/baselines.png width=738 alt="The top of the em square is roughly at the top of the glyphs in a font, the hanging baseline is where some glyphs like आ are anchored, the middle is half-way between the top of the em square and the bottom of the em square, the alphabetic baseline is where characters like Á, ÿ, f, and Ω are anchored, the ideographic baseline is where glyphs like " height=300>79C1; and 達 are anchored, and the bottom of the em square is roughly at the bottom of the glyphs in a font. The top and bottom of the bounding box can be far from these baselines, due to glyphs extending far outside the em square."></p>
<p>The keywords map to these alignment points as follows:</p>
@@ -60084,8 +60132,8 @@
</ul><p class=example>For example, if the user is using a keyboard to push a <code><a href=#the-button-element>button</a></code>
element by pressing the space bar, the element would match this pseudo-class in between the
- time that the element received the <code title=event-keydown>keydown</code> event and the
- time the element received the <code title=event-keyup>keyup</code> event.</p>
+ time that the element received the <code title=event-keydown><a href=#event-keydown>keydown</a></code> event and the
+ time the element received the <code title=event-keyup><a href=#event-keyup>keyup</a></code> event.</p>
</li>
@@ -64713,12 +64761,12 @@
running the event listener for a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event whose
type is in the following list:</p>
- <ul class=brief><li><code title=event-change>change</code></li>
+ <ul class=brief><li><code title=event-change><a href=#event-change>change</a></code></li>
<li><code title=event-click><a href=#event-click>click</a></code></li>
- <li><code title=event-dblclick>dblclick</code></li>
- <li><code title=event-mouseup>mouseup</code></li>
- <li><code title=event-reset>reset</code></li>
- <li><code title=event-submit>submit</code></li>
+ <li><code title=event-dblclick><a href=#event-dblclick>dblclick</a></code></li>
+ <li><code title=event-mouseup><a href=#event-mouseup>mouseup</a></code></li>
+ <li><code title=event-reset><a href=#event-reset>reset</a></code></li>
+ <li><code title=event-submit><a href=#event-submit>submit</a></code></li>
</ul></li>
<li>
@@ -65164,7 +65212,7 @@
<p>If <var title="">url</var> <em>is</em> "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing
context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue a task</a> to
- <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the selected
<a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected <a href=#browsing-context>browsing context</a>'s <a href=#concept-document-window title=concept-document-window><code>Window</code> object's <code>Document</code></a> object
(and the <code title=dom-event-currentTarget>currentTarget</code> set to the <code><a href=#window>Window</a></code>
object).</p>
@@ -66957,7 +67005,7 @@
<p>When the <dfn id=dom-location-reload title=dom-location-reload><code>reload()</code></dfn> method is invoked, the
user agent must run the appropriate steps from the following list:</p>
- <dl class=switch><dt>If the currently executing <a href=#concept-task title=concept-task>task</a> is the dispatch of a <code title=event-resize>resize</code> event in response to the user resizing the <a href=#browsing-context>browsing
+ <dl class=switch><dt>If the currently executing <a href=#concept-task title=concept-task>task</a> is the dispatch of a <code title=event-resize><a href=#event-resize>resize</a></code> event in response to the user resizing the <a href=#browsing-context>browsing
context</a></dt>
<dd><p>Repaint the <a href=#browsing-context>browsing context</a> and abort these steps.</dd> <!-- this
@@ -67825,7 +67873,7 @@
<!-- next two paragraphs are nearly identical to the navigate-text section, keep them in sync -->
<p>When no more bytes are available, the user agent must <a href=#queue-a-task>queue a task</a> for the parser
- to process the implied EOF character, which eventually causes a <code title=event-load>load</code> event to be fired.</p>
+ to process the implied EOF character, which eventually causes a <code title=event-load><a href=#event-load>load</a></code> event to be fired.</p>
<p>After creating the <code><a href=#document>Document</a></code> object, but before any script execution, certainly
before the parser <a href=#stop-parsing title="stop parsing">stops</a>, the user agent must <a href=#update-the-session-history-with-the-new-page>update the
@@ -67913,7 +67961,7 @@
navigate-plugin sections; keep them all in sync -->
<p>When no more bytes are available, the user agent must <a href=#queue-a-task>queue a task</a> for the parser
- to process the implied EOF character, which eventually causes a <code title=event-load>load</code> event to be fired.</p>
+ to process the implied EOF character, which eventually causes a <code title=event-load><a href=#event-load>load</a></code> event to be fired.</p>
<p>After creating the <code><a href=#document>Document</a></code> object, but potentially before the page has finished
parsing, the user agent must <a href=#update-the-session-history-with-the-new-page>update the session history with the new page</a>.</p>
@@ -67947,7 +67995,7 @@
resources, the user agent must act as if there were no more bytes for those resources whenever the
boundary following the body part is reached.</p>
- <p class=note>Thus, <code title=event-load>load</code> events (and for that matter <code title=event-unload>unload</code> events) do fire for each body part loaded.</p>
+ <p class=note>Thus, <code title=event-load><a href=#event-load>load</a></code> events (and for that matter <code title=event-unload><a href=#event-unload>unload</a></code> events) do fire for each body part loaded.</p>
<h4 id=read-media><span class=secno>6.6.6 </span><dfn title=navigate-media>Page load processing model for media</dfn></h4>
@@ -68347,14 +68395,11 @@
</ol><p>The <a href=#task-source>task source</a> for the tasks mentioned above is the <a href=#dom-manipulation-task-source>DOM manipulation task
source</a>.</p>
+ </div>
- <h5 id=event-definitions-1><span class=secno>6.6.10.1 </span>Event definitions</h5>
- </div>
+ <h5 id=the-popstateevent-interface><span class=secno>6.6.10.1 </span>The <code><a href=#popstateevent>PopStateEvent</a></code> interface</h5>
- <p>The <dfn id=event-popstate title=event-popstate><code>popstate</code></dfn> event is fired in certain cases
- when navigating to a <a href=#session-history-entry>session history entry</a>.</p>
-
<pre class=idl>[Constructor(DOMString type, optional <a href=#popstateeventinit>PopStateEventInit</a> eventInitDict)]
interface <dfn id=popstateevent>PopStateEvent</dfn> : <a href=#event>Event</a> {
readonly attribute any <a href=#dom-popstateevent-state title=dom-PopStateEvent-state>state</a>;
@@ -68381,10 +68426,9 @@
</div>
- <hr><p>The <dfn id=event-hashchange title=event-hashchange><code>hashchange</code></dfn> event is fired when navigating
- to a <a href=#session-history-entry>session history entry</a> whose <a href=#url>URL</a> differs from that of the previous
- one only in the fragment identifier.</p>
+ <h5 id=the-hashchangeevent-interface><span class=secno>6.6.10.2 </span>The <code><a href=#hashchangeevent>HashChangeEvent</a></code> interface</h5>
+
<pre class=idl>[Constructor(DOMString type, optional <a href=#hashchangeeventinit>HashChangeEventInit</a> eventInitDict)]
interface <dfn id=hashchangeevent>HashChangeEvent</dfn> : <a href=#event>Event</a> {
readonly attribute DOMString <a href=#dom-hashchangeevent-oldurl title=dom-HashChangeEvent-oldURL>oldURL</a>;
@@ -68429,13 +68473,9 @@
</div>
- <hr><p>The <dfn id=event-pageshow title=event-pageshow><code>pageshow</code></dfn> event is fired when <a href=#traverse-the-history title="traverse the history">traversing</a> <em>to</em> a <a href=#session-history-entry>session history entry</a>.
- The <dfn id=event-pagehide title=event-pagehide><code>pagehide</code></dfn> event is fired when traversing
- <em>from</em> a <a href=#session-history-entry>session history entry</a>. The specification uses the <a href=#page-showing>page
- showing</a> flag to ensure that scripts receive these events in a consistent manner (e.g. that
- they never receive two <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a row without an
- intervening <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code>, or vice versa).</p>
+ <h5 id=the-pagetransitionevent-interface><span class=secno>6.6.10.3 </span>The <code><a href=#pagetransitionevent>PageTransitionEvent</a></code> interface</h5>
+
<pre class=idl>[Constructor(DOMString type, optional <a href=#pagetransitioneventinit>PageTransitionEventInit</a> eventInitDict)]
interface <dfn id=pagetransitionevent>PageTransitionEvent</dfn> : <a href=#event>Event</a> {
readonly attribute boolean <a href=#dom-pagetransitionevent-persisted title=dom-PageTransitionEvent-persisted>persisted</a>;
@@ -68450,7 +68490,7 @@
<dd>
<p>For the <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> event, returns false if the page is
- newly being loaded (and the <code title=event-load>load</code> event will fire). Otherwise,
+ newly being loaded (and the <code title=event-load><a href=#event-load>load</a></code> event will fire). Otherwise,
returns true.</p>
<p>For the <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> event, returns false if the page is
@@ -68461,8 +68501,8 @@
<p>Things that can cause the page to be unsalvageable include:</p>
<ul class=brief><li><code title=dom-document-open><a href=#dom-document-open>document.open()</a></code>
- <li>Listening for <code title=event-beforeunload>beforeunload</code> events
- <li>Listening for <code title=event-unload>unload</code> events
+ <li>Listening for <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> events
+ <li>Listening for <code title=event-unload><a href=#event-unload>unload</a></code> events
<li>Having <code><a href=#the-iframe-element>iframe</a></code>s that are not salvageable
<li>Active <code><a href=#websocket>WebSocket</a></code> objects
<li><a href=#abort-a-document title="abort a document">Aborting a <code>Document</code></a>
@@ -68482,9 +68522,12 @@
<div class=impl>
- <p>A <code><a href=#document>Document</a></code> has a <dfn id=concept-document-salvageable title=concept-document-salvageable><i>salvageable</i></dfn> state, which must initially be true,
- a <dfn id=fired-unload>fired unload</dfn> flag, which must initially be false, and a <dfn id=page-showing>page showing</dfn> flag,
- which must initially be false.</p>
+ <p>A <code><a href=#document>Document</a></code> has a <dfn id=concept-document-salvageable title=concept-document-salvageable><i>salvageable</i></dfn> state, which must initially be
+ true, a <dfn id=fired-unload>fired unload</dfn> flag, which must initially be false, and a <dfn id=page-showing>page showing</dfn>
+ flag, which must initially be false. The <a href=#page-showing>page showing</a> flag is used to ensure that
+ scripts receive <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> and <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a consistent manner (e.g. that they never
+ receive two <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code> events in a row without an intervening
+ <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code>, or vice versa).</p>
<p><a href=#event-loop title="event loop">Event loops</a> have a <dfn id=termination-nesting-level>termination nesting level</dfn>
counter, which must initially be zero.</p>
@@ -68499,7 +68542,7 @@
one.</li>
<li><p>Let <var title="">event</var> be a new <a href=#concept-events-trusted title=concept-events-trusted>trusted</a>
- <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> event object with the name <code title=event-beforeunload>beforeunload</code>, which does not bubble but is cancelable.</li>
+ <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> event object with the name <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code>, which does not bubble but is cancelable.</li>
<li><p><i>Dispatch</i>: <a href=#concept-event-dispatch title=concept-event-dispatch>Dispatch</a> <var title="">event</var> at the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object.</li>
@@ -68592,7 +68635,7 @@
</li>
<li><p><i>Unload event</i>: If the <code><a href=#document>Document</a></code>'s <a href=#fired-unload>fired unload</a> flag is
- false, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-unload>unload</code> at the
+ false, <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-unload><a href=#event-unload>unload</a></code> at the
<code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object.</li>
<li><p>Decrease the <a href=#event-loop>event loop</a>'s <a href=#termination-nesting-level>termination nesting level</a> by
@@ -68659,10 +68702,12 @@
state is false, empty the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code>'s <a href=#list-of-active-timers>list of active
timers</a>.</li>
- </ol><h5 id=event-definition><span class=secno>6.6.11.1 </span>Event definition</h5>
+ </ol></div>
- </div>
+
+ <h5 id=the-beforeunloadevent-interface><span class=secno>6.6.11.1 </span>The <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code> interface</h5>
+
<pre class=idl>interface <dfn id=beforeunloadevent>BeforeUnloadEvent</dfn> : <a href=#event>Event</a> {
attribute DOMString <a href=#dom-beforeunloadevent-returnvalue title=dom-BeforeUnloadEvent-returnValue>returnValue</a>;
};</pre>
@@ -68717,7 +68762,7 @@
</ol><p>User agents may allow users to explicitly invoke the <a href=#abort-a-document title="abort a document">abort a
document</a> algorithm for a <code><a href=#document>Document</a></code>. If the user does so, then, if that
<code><a href=#document>Document</a></code> is an <a href=#active-document>active document</a>, the user agent should <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-abort>abort</code> at
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-abort><a href=#event-abort>abort</a></code> at
that <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object before invoking the <a href=#abort-a-document title="abort a
document">abort</a> algorithm.</p>
@@ -69641,7 +69686,7 @@
progress</dfn>. Support for this is optional. Caching progress UI could consist of a progress bar
or message panel in the user agent's interface, or an overlay, or something else. Certain events
fired during the <a href=#application-cache-download-process>application cache download process</a> allow the script to override the
- display of such an interface. (Such events are delayed until after the <code title=event-load>load</code> event has fired.)
+ display of such an interface. (Such events are delayed until after the <code title=event-load><a href=#event-load>load</a></code> event has fired.)
The goal of this is to allow Web applications to provide more
seamless update mechanisms, hiding from the user the mechanics of the application cache mechanism.
@@ -70239,7 +70284,7 @@
site.</p>
<hr><p>Each <code><a href=#document>Document</a></code> has a list of <dfn id=pending-application-cache-download-process-tasks>pending application cache download process
- tasks</dfn> that is used to delay events fired by the algorithm above until the document's <code title=event-load>load</code> event has fired. When the <code><a href=#document>Document</a></code> is created, the
+ tasks</dfn> that is used to delay events fired by the algorithm above until the document's <code title=event-load><a href=#event-load>load</a></code> event has fired. When the <code><a href=#document>Document</a></code> is created, the
list must be empty.</p>
<p>When the steps above say to <dfn id=queue-a-post-load-task>queue a post-load task</dfn> <var title="">task</var>, where
@@ -70671,14 +70716,16 @@
requests a remote page (or knows that such an attempt would fail), and must return true
otherwise.</p>
+<!--CLEANUP-->
<p>When the value that would be returned by the <code title=dom-navigator-onLine><a href=#dom-navigator-online>navigator.onLine</a></code> attribute of a <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> changes from true to false, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-offline title=event-offline><code>offline</code></dfn> at the <code><a href=#window>Window</a></code> or
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-offline><a href=#event-offline>offline</a></code> at the <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object.</p>
+<!--CLEANUP-->
<p>On the other hand, when the value that would be returned by the <code title=dom-navigator-onLine><a href=#dom-navigator-online>navigator.onLine</a></code> attribute of a <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> changes from false to true, the user agent must <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <dfn id=event-online title=event-online><code>online</code></dfn> at the <code><a href=#window>Window</a></code> or
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-online><a href=#event-online>online</a></code> at the <code><a href=#window>Window</a></code> or
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object.</p>
<p>The <a href=#task-source>task source</a> for these <a href=#concept-task title=concept-task>tasks</a> is the
@@ -71204,7 +71251,7 @@
<a href=#browsing-context>browsing context</a>.</p>
<p class=example>For example, the prompt mentioned in the example above could also offer the
- user with a mechanism to just close the page entirely, without running any <code title=event-unload>unload</code> event handlers.</p>
+ user with a mechanism to just close the page entirely, without running any <code title=event-unload><a href=#event-unload>unload</a></code> event handlers.</p>
</div>
@@ -71262,7 +71309,7 @@
<li><p>Let <var title="">event</var> be a new <a href=#concept-events-trusted title=concept-events-trusted>trusted</a>
<code><a href=#errorevent>ErrorEvent</a></code> object that does not bubble but is cancelable, and which has the event
- name <code title=event-error>error</code>.</li>
+ name <code title=event-error><a href=#event-error>error</a></code>.</li>
<li><p>Initialize <var title="">event</var>'s <code title=dom-ErrorEvent-message><a href=#dom-errorevent-message>message</a></code>
attribute to <var title="">message</var>.</li>
@@ -71888,7 +71935,7 @@
<p class=note>The return value of the function affects whether the event is canceled or not:
<span class=impl>as described above,</span> if the return value is false, the event is canceled
(except for <code class=event-mouseover>mouseover</code> events, where the return value has to
- be true to cancel the event). With <code title=event-beforeunload>beforeunload</code> events,
+ be true to cancel the event). With <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> events,
the value is instead used to determine the message to show the user.</p>
<p>For historical reasons, the <code title=handler-onerror><a href=#handler-onerror>onerror</a></code> handler has different
@@ -72081,66 +72128,66 @@
attributes</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-onabort title=handler-onabort><code>onabort</code></dfn> <td> <code title=event-abort>abort</code>
+ <tbody><tr><td><dfn id=handler-onabort title=handler-onabort><code>onabort</code></dfn> <td> <code title=event-abort><a href=#event-abort>abort</a></code>
<tr><td><dfn id=handler-oncancel title=handler-oncancel><code>oncancel</code></dfn> <td> <code title=event-cancel><a href=#event-cancel>cancel</a></code>
<tr><td><dfn id=handler-oncanplay title=handler-oncanplay><code>oncanplay</code></dfn> <td> <code title=event-media-canplay><a href=#event-media-canplay>canplay</a></code>
<tr><td><dfn id=handler-oncanplaythrough title=handler-oncanplaythrough><code>oncanplaythrough</code></dfn> <td> <code title=event-media-canplaythrough><a href=#event-media-canplaythrough>canplaythrough</a></code>
- <tr><td><dfn id=handler-onchange title=handler-onchange><code>onchange</code></dfn> <td> <code title=event-change>change</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onchange title=handler-onchange><code>onchange</code></dfn> <td> <code title=event-change><a href=#event-change>change</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onclick title=handler-onclick><code>onclick</code></dfn> <td> <code title=event-click><a href=#event-click>click</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onclose title=handler-onclose><code>onclose</code></dfn> <td> <code title=event-close><a href=#event-close>close</a></code> <!-- new for <dialog> -->
- <tr><td><dfn id=handler-oncontextmenu title=handler-oncontextmenu><code>oncontextmenu</code></dfn> <td> <code title=event-contextmenu>contextmenu</code> <!-- widely used -->
- <tr><td><dfn id=handler-oncuechange title=handler-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-cuechange>cuechange</code>
- <tr><td><dfn id=handler-ondblclick title=handler-ondblclick><code>ondblclick</code></dfn> <td> <code title=event-dblclick>dblclick</code> <!-- widely used -->
- <tr><td><dfn id=handler-ondrag title=handler-ondrag><code>ondrag</code></dfn> <td> <code title=event-drag><a href=#event-drag>drag</a></code>
- <tr><td><dfn id=handler-ondragend title=handler-ondragend><code>ondragend</code></dfn> <td> <code title=event-dragend><a href=#event-dragend>dragend</a></code>
- <tr><td><dfn id=handler-ondragenter title=handler-ondragenter><code>ondragenter</code></dfn> <td> <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code>
- <tr><td><dfn id=handler-ondragexit title=handler-ondragexit><code>ondragexit</code></dfn> <td> <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>
- <tr><td><dfn id=handler-ondragleave title=handler-ondragleave><code>ondragleave</code></dfn> <td> <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>
- <tr><td><dfn id=handler-ondragover title=handler-ondragover><code>ondragover</code></dfn> <td> <code title=event-dragover><a href=#event-dragover>dragover</a></code>
- <tr><td><dfn id=handler-ondragstart title=handler-ondragstart><code>ondragstart</code></dfn> <td> <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> <!-- widely used -->
- <tr><td><dfn id=handler-ondrop title=handler-ondrop><code>ondrop</code></dfn> <td> <code title=event-drop><a href=#event-drop>drop</a></code>
+ <tr><td><dfn id=handler-oncontextmenu title=handler-oncontextmenu><code>oncontextmenu</code></dfn> <td> <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-oncuechange title=handler-oncuechange><code>oncuechange</code></dfn> <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code>
+ <tr><td><dfn id=handler-ondblclick title=handler-ondblclick><code>ondblclick</code></dfn> <td> <code title=event-dblclick><a href=#event-dblclick>dblclick</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-ondrag title=handler-ondrag><code>ondrag</code></dfn> <td> <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code>
+ <tr><td><dfn id=handler-ondragend title=handler-ondragend><code>ondragend</code></dfn> <td> <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>
+ <tr><td><dfn id=handler-ondragenter title=handler-ondragenter><code>ondragenter</code></dfn> <td> <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code>
+ <tr><td><dfn id=handler-ondragexit title=handler-ondragexit><code>ondragexit</code></dfn> <td> <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>
+ <tr><td><dfn id=handler-ondragleave title=handler-ondragleave><code>ondragleave</code></dfn> <td> <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>
+ <tr><td><dfn id=handler-ondragover title=handler-ondragover><code>ondragover</code></dfn> <td> <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>
+ <tr><td><dfn id=handler-ondragstart title=handler-ondragstart><code>ondragstart</code></dfn> <td> <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-ondrop title=handler-ondrop><code>ondrop</code></dfn> <td> <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code>
<tr><td><dfn id=handler-ondurationchange title=handler-ondurationchange><code>ondurationchange</code></dfn> <td> <code title=event-media-durationchange><a href=#event-media-durationchange>durationchange</a></code>
<tr><td><dfn id=handler-onemptied title=handler-onemptied><code>onemptied</code></dfn> <td> <code title=event-media-emptied><a href=#event-media-emptied>emptied</a></code>
<tr><td><dfn id=handler-onended title=handler-onended><code>onended</code></dfn> <td> <code title=event-media-ended><a href=#event-media-ended>ended</a></code>
- <tr><td><dfn id=handler-oninput title=handler-oninput><code>oninput</code></dfn> <td> <code title=event-input>input</code>
- <tr><td><dfn id=handler-oninvalid title=handler-oninvalid><code>oninvalid</code></dfn> <td> <code title=event-invalid>invalid</code>
- <tr><td><dfn id=handler-onkeydown title=handler-onkeydown><code>onkeydown</code></dfn> <td> <code title=event-keydown>keydown</code> <!-- widely used -->
- <tr><td><dfn id=handler-onkeypress title=handler-onkeypress><code>onkeypress</code></dfn> <td> <code title=event-keypress>keypress</code> <!-- widely used -->
- <tr><td><dfn id=handler-onkeyup title=handler-onkeyup><code>onkeyup</code></dfn> <td> <code title=event-keyup>keyup</code> <!-- widely used -->
+ <tr><td><dfn id=handler-oninput title=handler-oninput><code>oninput</code></dfn> <td> <code title=event-input><a href=#event-input>input</a></code>
+ <tr><td><dfn id=handler-oninvalid title=handler-oninvalid><code>oninvalid</code></dfn> <td> <code title=event-invalid><a href=#event-invalid>invalid</a></code>
+ <tr><td><dfn id=handler-onkeydown title=handler-onkeydown><code>onkeydown</code></dfn> <td> <code title=event-keydown><a href=#event-keydown>keydown</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onkeypress title=handler-onkeypress><code>onkeypress</code></dfn> <td> <code title=event-keypress><a href=#event-keypress>keypress</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onkeyup title=handler-onkeyup><code>onkeyup</code></dfn> <td> <code title=event-keyup><a href=#event-keyup>keyup</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onloadeddata title=handler-onloadeddata><code>onloadeddata</code></dfn> <td> <code title=event-media-loadeddata><a href=#event-media-loadeddata>loadeddata</a></code>
<tr><td><dfn id=handler-onloadedmetadata title=handler-onloadedmetadata><code>onloadedmetadata</code></dfn> <td> <code title=event-media-loadedmetadata><a href=#event-media-loadedmetadata>loadedmetadata</a></code>
<tr><td><dfn id=handler-onloadstart title=handler-onloadstart><code>onloadstart</code></dfn> <td> <code title=event-media-loadstart><a href=#event-media-loadstart>loadstart</a></code>
- <tr><td><dfn id=handler-onmousedown title=handler-onmousedown><code>onmousedown</code></dfn> <td> <code title=event-mousedown>mousedown</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseenter title=handler-onmouseenter><code>onmouseenter</code></dfn> <td> <code title=event-mouseenter>mouseenter</code> <!-- compat -->
- <tr><td><dfn id=handler-onmouseleave title=handler-onmouseleave><code>onmouseleave</code></dfn> <td> <code title=event-mouseleave>mouseleave</code> <!-- compat -->
- <tr><td><dfn id=handler-onmousemove title=handler-onmousemove><code>onmousemove</code></dfn> <td> <code title=event-mousemove>mousemove</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseout title=handler-onmouseout><code>onmouseout</code></dfn> <td> <code title=event-mouseout>mouseout</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseover title=handler-onmouseover><code>onmouseover</code></dfn> <td> <code title=event-mouseover>mouseover</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmouseup title=handler-onmouseup><code>onmouseup</code></dfn> <td> <code title=event-mouseup>mouseup</code> <!-- widely used -->
- <tr><td><dfn id=handler-onmousewheel title=handler-onmousewheel><code>onmousewheel</code></dfn> <td> <code title=event-mousewheel>mousewheel</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmousedown title=handler-onmousedown><code>onmousedown</code></dfn> <td> <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseenter title=handler-onmouseenter><code>onmouseenter</code></dfn> <td> <code title=event-mouseenter><a href=#event-mouseenter>mouseenter</a></code> <!-- compat -->
+ <tr><td><dfn id=handler-onmouseleave title=handler-onmouseleave><code>onmouseleave</code></dfn> <td> <code title=event-mouseleave><a href=#event-mouseleave>mouseleave</a></code> <!-- compat -->
+ <tr><td><dfn id=handler-onmousemove title=handler-onmousemove><code>onmousemove</code></dfn> <td> <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseout title=handler-onmouseout><code>onmouseout</code></dfn> <td> <code title=event-mouseout><a href=#event-mouseout>mouseout</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseover title=handler-onmouseover><code>onmouseover</code></dfn> <td> <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmouseup title=handler-onmouseup><code>onmouseup</code></dfn> <td> <code title=event-mouseup><a href=#event-mouseup>mouseup</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onmousewheel title=handler-onmousewheel><code>onmousewheel</code></dfn> <td> <code title=event-mousewheel><a href=#event-mousewheel>mousewheel</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onpause title=handler-onpause><code>onpause</code></dfn> <td> <code title=event-media-pause><a href=#event-media-pause>pause</a></code>
<tr><td><dfn id=handler-onplay title=handler-onplay><code>onplay</code></dfn> <td> <code title=event-media-play><a href=#event-media-play>play</a></code>
<tr><td><dfn id=handler-onplaying title=handler-onplaying><code>onplaying</code></dfn> <td> <code title=event-media-playing><a href=#event-media-playing>playing</a></code>
<tr><td><dfn id=handler-onprogress title=handler-onprogress><code>onprogress</code></dfn> <td> <code title=event-media-progress><a href=#event-media-progress>progress</a></code>
<tr><td><dfn id=handler-onratechange title=handler-onratechange><code>onratechange</code></dfn> <td> <code title=event-media-ratechange><a href=#event-media-ratechange>ratechange</a></code>
- <tr><td><dfn id=handler-onreset title=handler-onreset><code>onreset</code></dfn> <td> <code title=event-reset>reset</code>
+ <tr><td><dfn id=handler-onreset title=handler-onreset><code>onreset</code></dfn> <td> <code title=event-reset><a href=#event-reset>reset</a></code>
<tr><td><dfn id=handler-onseeked title=handler-onseeked><code>onseeked</code></dfn> <td> <code title=event-media-seeked><a href=#event-media-seeked>seeked</a></code>
<tr><td><dfn id=handler-onseeking title=handler-onseeking><code>onseeking</code></dfn> <td> <code title=event-media-seeking><a href=#event-media-seeking>seeking</a></code>
- <tr><td><dfn id=handler-onselect title=handler-onselect><code>onselect</code></dfn> <td> <code title=event-select>select</code> <!-- widely used --> <!-- [CSSOM] -->
- <tr><td><dfn id=handler-onshow title=handler-onshow><code>onshow</code></dfn> <td> <code title=event-show>show</code>
- <tr><td><dfn id=handler-onsort title=handler-onsort><code>onsort</code></dfn> <td> <code title=event-sort>sort</code>
+ <tr><td><dfn id=handler-onselect title=handler-onselect><code>onselect</code></dfn> <td> <code title=event-select><a href=#event-select>select</a></code> <!-- widely used --> <!-- [CSSOM] -->
+ <tr><td><dfn id=handler-onshow title=handler-onshow><code>onshow</code></dfn> <td> <code title=event-show><a href=#event-show>show</a></code>
+ <tr><td><dfn id=handler-onsort title=handler-onsort><code>onsort</code></dfn> <td> <code title=event-sort><a href=#event-sort>sort</a></code>
<tr><td><dfn id=handler-onstalled title=handler-onstalled><code>onstalled</code></dfn> <td> <code title=event-media-stalled><a href=#event-media-stalled>stalled</a></code>
- <tr><td><dfn id=handler-onsubmit title=handler-onsubmit><code>onsubmit</code></dfn> <td> <code title=event-submit>submit</code> <!-- widely used -->
+ <tr><td><dfn id=handler-onsubmit title=handler-onsubmit><code>onsubmit</code></dfn> <td> <code title=event-submit><a href=#event-submit>submit</a></code> <!-- widely used -->
<tr><td><dfn id=handler-onsuspend title=handler-onsuspend><code>onsuspend</code></dfn> <td> <code title=event-media-suspend><a href=#event-media-suspend>suspend</a></code>
<tr><td><dfn id=handler-ontimeupdate title=handler-ontimeupdate><code>ontimeupdate</code></dfn> <td> <code title=event-media-timeupdate><a href=#event-media-timeupdate>timeupdate</a></code>
- <tr><td><dfn id=handler-ontoggle title=handler-ontoggle><code>ontoggle</code></dfn> <td> <code title=event-toggle>toggle</code>
+ <tr><td><dfn id=handler-ontoggle title=handler-ontoggle><code>ontoggle</code></dfn> <td> <code title=event-toggle><a href=#event-toggle>toggle</a></code>
<tr><td><dfn id=handler-onvolumechange title=handler-onvolumechange><code>onvolumechange</code></dfn> <td> <code title=event-media-volumechange><a href=#event-media-volumechange>volumechange</a></code>
<tr><td><dfn id=handler-onwaiting title=handler-onwaiting><code>onwaiting</code></dfn> <td> <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code>
<!-- not supported, use dnd: -->
-<!--<tr><td><dfn title="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code title="event-beforecopy">beforecopy</code>--> <!-- widely used -->
-<!--<tr><td><dfn title="handler-oncopy"><code>oncopy</code></dfn> <td> <code title="event-copy">copy</code>--> <!-- widely used -->
-<!--<tr><td><dfn title="handler-onpaste"><code>onpaste</code></dfn> <td> <code title="event-paste">paste</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code title="event-cp-beforecopy">beforecopy</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-oncopy"><code>oncopy</code></dfn> <td> <code title="event-cp-copy">copy</code>--> <!-- widely used -->
+<!--<tr><td><dfn title="handler-onpaste"><code>onpaste</code></dfn> <td> <code title="event-cp-paste">paste</code>--> <!-- widely used -->
<!-- not supported yet (v2?): -->
<!--<tr><td><dfn title="handler-onselectstart"><code>onselectstart</code></dfn> <td> <code title="event-selectstart">selectstart</code>--> <!-- widely used -->
</table><hr><p>The following are the <a href=#event-handlers>event handlers</a> (and their corresponding <a href=#event-handler-event-type title="event
@@ -72156,12 +72203,12 @@
<code>Window</code> object's <code>Document</code>s</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-onblur title=handler-onblur><code>onblur</code></dfn> <td> <code title=event-blur>blur</code> <!-- widely used -->
- <tr><td><dfn id=handler-onerror title=handler-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
- <tr><td><dfn id=handler-onfocus title=handler-onfocus><code>onfocus</code></dfn> <td> <code title=event-focus>focus</code> <!-- widely used -->
- <tr><td><dfn id=handler-onload title=handler-onload><code>onload</code></dfn> <td> <code title=event-load>load</code>
- <tr><td><dfn id=handler-onresize title=handler-onresize><code>onresize</code></dfn> <td> <code title=event-resize>resize</code>
- <tr><td><dfn id=handler-onscroll title=handler-onscroll><code>onscroll</code></dfn> <td> <code title=event-scroll>scroll</code>
+ <tbody><tr><td><dfn id=handler-onblur title=handler-onblur><code>onblur</code></dfn> <td> <code title=event-blur><a href=#event-blur>blur</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onerror title=handler-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+ <tr><td><dfn id=handler-onfocus title=handler-onfocus><code>onfocus</code></dfn> <td> <code title=event-focus><a href=#event-focus>focus</a></code> <!-- widely used -->
+ <tr><td><dfn id=handler-onload title=handler-onload><code>onload</code></dfn> <td> <code title=event-load><a href=#event-load>load</a></code>
+ <tr><td><dfn id=handler-onresize title=handler-onresize><code>onresize</code></dfn> <td> <code title=event-resize><a href=#event-resize>resize</a></code>
+ <tr><td><dfn id=handler-onscroll title=handler-onscroll><code>onscroll</code></dfn> <td> <code title=event-scroll><a href=#event-scroll>scroll</a></code>
</table><hr><p>The following are the <a href=#event-handlers>event handlers</a> (and their corresponding <a href=#event-handler-event-type title="event
handler event type">event handler event types</a>) <span class=impl>that must be</span>
supported by <code><a href=#window>Window</a></code> objects, as <a href=#event-handler-idl-attributes>event handler IDL attributes</a> on the
@@ -72171,9 +72218,9 @@
<code>Window</code> object's <code>Document</code>s</a>:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-window-onafterprint title=handler-window-onafterprint><code>onafterprint</code></dfn> <td> <code title=event-afterprint>afterprint</code>
- <tr><td><dfn id=handler-window-onbeforeprint title=handler-window-onbeforeprint><code>onbeforeprint</code></dfn> <td> <code title=event-beforeprint>beforeprint</code>
- <tr><td><dfn id=handler-window-onbeforeunload title=handler-window-onbeforeunload><code>onbeforeunload</code></dfn> <td> <code title=event-beforeunload>beforeunload</code>
+ <tbody><tr><td><dfn id=handler-window-onafterprint title=handler-window-onafterprint><code>onafterprint</code></dfn> <td> <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code>
+ <tr><td><dfn id=handler-window-onbeforeprint title=handler-window-onbeforeprint><code>onbeforeprint</code></dfn> <td> <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code>
+ <tr><td><dfn id=handler-window-onbeforeunload title=handler-window-onbeforeunload><code>onbeforeunload</code></dfn> <td> <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code>
<tr><td><dfn id=handler-window-onhashchange title=handler-window-onhashchange><code>onhashchange</code></dfn> <td> <code title=event-hashchange><a href=#event-hashchange>hashchange</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onmessage title=handler-window-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code> <!-- new for postMessage -->
<tr><td><dfn id=handler-window-onoffline title=handler-window-onoffline><code>onoffline</code></dfn> <td> <code title=event-offline><a href=#event-offline>offline</a></code> <!-- new -->
@@ -72182,7 +72229,7 @@
<tr><td><dfn id=handler-window-onpageshow title=handler-window-onpageshow><code>onpageshow</code></dfn> <td> <code title=event-pageshow><a href=#event-pageshow>pageshow</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onpopstate title=handler-window-onpopstate><code>onpopstate</code></dfn> <td> <code title=event-popstate><a href=#event-popstate>popstate</a></code> <!-- new -->
<tr><td><dfn id=handler-window-onstorage title=handler-window-onstorage><code>onstorage</code></dfn> <td> <code title=event-storage><a href=#event-storage>storage</a></code> <!-- new -->
- <tr><td><dfn id=handler-window-onunload title=handler-window-onunload><code>onunload</code></dfn> <td> <code title=event-unload>unload</code> <!-- widely used -->
+ <tr><td><dfn id=handler-window-onunload title=handler-window-onunload><code>onunload</code></dfn> <td> <code title=event-unload><a href=#event-unload>unload</a></code> <!-- widely used -->
</table><hr><!-- this guy is only on Document and not on HTMLElement because otherwise HTMLScriptElement would
have it and that causes compatibility issues since IE fires readystatechange events on <script>,
not load events, and we can't fire both, and some sites try to decide which to look for based on
@@ -72316,7 +72363,7 @@
<h5 id=events-and-the-window-object><span class=secno>7.1.5.4 </span>Events and the <code><a href=#window>Window</a></code> object</h5>
<p>When an event is dispatched at a DOM node in a <code><a href=#document>Document</a></code> in a <a href=#browsing-context>browsing
- context</a>, if the event is not a <code title=event-load>load</code> event, the user agent
+ context</a>, if the event is not a <code title=event-load><a href=#event-load>load</a></code> event, the user agent
must act as if, for the purposes of <a href=#concept-event-dispatch title=concept-event-dispatch>event dispatching</a>,
the <code><a href=#window>Window</a></code> object is the parent of the <code><a href=#document>Document</a></code> object. <a href=#refsDOM>[DOM]</a></p>
@@ -72632,7 +72679,7 @@
<code><a href=#document>Document</a></code> object on which the method was invoked.</p>
<p class=note>This basically causes <code title=dom-document-open><a href=#dom-document-open>document.open()</a></code> to
- be ignored when it's called from a <code title=event-beforeunload>beforeunload</code> <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code>, or <code title=event-unload>unload</code> event
+ be ignored when it's called from a <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> <code title=event-pagehide><a href=#event-pagehide>pagehide</a></code>, or <code title=event-unload><a href=#event-unload>unload</a></code> event
handler while the <code><a href=#document>Document</a></code> is being unloaded.</p>
</li>
@@ -73412,11 +73459,11 @@
<li>
- <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-beforeprint>beforeprint</code> at the <code><a href=#window>Window</a></code> object of the
+ <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> at the <code><a href=#window>Window</a></code> object of the
<code><a href=#document>Document</a></code> that is being printed, as well as any <a href=#nested-browsing-context title="nested browsing
context">nested browsing contexts</a> in it.</p>
- <p class=example>The <code title=event-beforeprint>beforeprint</code> event can be used to
+ <p class=example>The <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> event can be used to
annotate the printed copy, for instance adding the time at which the document was printed.</p>
</li>
@@ -73440,11 +73487,11 @@
<li>
- <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-afterprint>afterprint</code> at the <code><a href=#window>Window</a></code> object of the
+ <p>The user agent must <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> at the <code><a href=#window>Window</a></code> object of the
<code><a href=#document>Document</a></code> that is being printed, as well as any <a href=#nested-browsing-context title="nested browsing
context">nested browsing contexts</a> in it.</p>
- <p class=example>The <code title=event-afterprint>afterprint</code> event can be used to
+ <p class=example>The <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> event can be used to
revert annotations added in the earlier event, as well as showing post-printing UI. For
instance, if a page is walking the user through the steps of applying for a home loan, the
script could automatically advance to the next step after having printed a form or other.</p>
@@ -75505,7 +75552,7 @@
<p class=example>For example, consider a page that consists of just a single <a href=#inert>inert</a>
paragraph positioned in the middle of a <code><a href=#the-body-element>body</a></code>. If a user moves their pointing device
from the <code><a href=#the-body-element>body</a></code> over to the <a href=#inert>inert</a> paragraph and clicks on the paragraph,
- no <code title=event-mouseover>mouseover</code> event would be fired, and the <code title=event-mousemove>mousemove</code> and <code title=event-click><a href=#event-click>click</a></code> events would
+ no <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> event would be fired, and the <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> and <code title=event-click><a href=#event-click>click</a></code> events would
be fired on the <code><a href=#the-body-element>body</a></code> element rather than the paragraph.</p>
<!--CLEANUP-->
@@ -75827,7 +75874,7 @@
</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-focus>focus</code> at the element.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-focus><a href=#event-focus>focus</a></code> at the element.</li>
<!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/723 -->
</ol><p>User agents must synchronously run the <a href=#focusing-steps>focusing steps</a> for an element whenever the
@@ -75837,11 +75884,11 @@
<ol><li><p>If the element is an <code><a href=#the-input-element>input</a></code> element, and the <code title=event-input-change><a href=#event-input-change>change</a></code> event applies to the element, and the element does not
have a defined <a href=#activation-behavior>activation behavior</a>, and the user has changed the element's <a href=#concept-fe-value title=concept-fe-value>value</a> or its list of <a href=#concept-input-type-file-selected title=concept-input-type-file-selected>selected files</a> while the control was focused
- without committing that change, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change>change</code> at the element.</p>
+ without committing that change, then <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-change><a href=#event-change>change</a></code> at the element.</p>
<li><p>Unfocus the element.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-blur>blur</code> at the element.</li>
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-blur><a href=#event-blur>blur</a></code> at the element.</li>
<!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/723 -->
</ol><p>When an element that is focused stops being a <a href=#focusable>focusable</a> element, or stops being
@@ -76603,7 +76650,7 @@
is.</p>
<p>On a visual medium with a pointing device, a drag operation could be the default action of a
- <code title=event-mousedown>mousedown</code> event that is followed by a series of <code title=event-mousemove>mousemove</code> events, and the drop could be triggered by the mouse
+ <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> event that is followed by a series of <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> events, and the drop could be triggered by the mouse
being released.</p>
<p>When using an input modality other than a pointing device, users would probably have to
@@ -76628,7 +76675,7 @@
<p><i>This section is non-normative.</i></p>
- <p>To make an element draggable is simple: give the element a <code title=attr-draggable><a href=#the-draggable-attribute>draggable</a></code> attribute, and set an event listener for <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> that stores the data being dragged.</p>
+ <p>To make an element draggable is simple: give the element a <code title=attr-draggable><a href=#the-draggable-attribute>draggable</a></code> attribute, and set an event listener for <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> that stores the data being dragged.</p>
<p>The event handler typically needs to check that it's not a text selection that is being
dragged, and then needs to store data into the <code><a href=#datatransfer>DataTransfer</a></code> object and set the
@@ -76664,11 +76711,11 @@
"<code>move</code>" to indicate that the data will be moved).</p>
<p class=note>Instead of using the <code title=attr-dropzone><a href=#the-dropzone-attribute>dropzone</a></code> attribute, a drop
- target can handle the <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> event (to report whether or
- not the drop target is to accept the drop) and the <code title=event-dragover><a href=#event-dragover>dragover</a></code>
+ target can handle the <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> event (to report whether or
+ not the drop target is to accept the drop) and the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>
event (to specify what feedback is to be shown to the user).</p>
- <p>The <code title=event-drop><a href=#event-drop>drop</a></code> event allows the actual drop to be performed. This
+ <p>The <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event allows the actual drop to be performed. This
event needs to be canceled, so that the <code title=dom-DataTransfer-DropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute's value can be used by the source
(otherwise it's reset).</p>
@@ -76697,7 +76744,7 @@
}
</script></pre>
- <hr><p>To remove the original element (the one that was dragged) from the display, the <code title=event-dragend><a href=#event-dragend>dragend</a></code> event can be used.</p>
+ <hr><p>To remove the original element (the one that was dragged) from the display, the <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event can be used.</p>
<p>For our example here, that means updating the original markup to handle that event:</p>
@@ -76809,7 +76856,7 @@
<dl><dt><dfn id=concept-dnd-rw title=concept-dnd-rw>Read/write mode</dfn></dt>
<dd>
- <p>For the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event. New data can be added to the
+ <p>For the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event. New data can be added to the
<a href=#drag-data-store>drag data store</a>.</p>
</dd>
@@ -76817,7 +76864,7 @@
<dt><dfn id=concept-dnd-ro title=concept-dnd-ro>Read-only mode</dfn></dt>
<dd>
- <p>For the <code title=event-drop><a href=#event-drop>drop</a></code> event. The list of items representing dragged
+ <p>For the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event. The list of items representing dragged
data can be read, including the data. No new data can be added.</p>
</dd>
@@ -76888,7 +76935,7 @@
<p>Returns the kinds of operations that are to be allowed.</p>
- <p>Can be set (during the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event), to change the
+ <p>Can be set (during the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event), to change the
allowed operations.</p>
<p>The possible values are "<code title="">none</code>", "<code title="">copy</code>", "<code title="">copyLink</code>", "<code title="">copyMove</code>", "<code title="">link</code>",
@@ -76921,7 +76968,7 @@
<dd>
- <p>Returns an array listing the formats that were set in the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event. In addition, if any files are being dragged,
+ <p>Returns an array listing the formats that were set in the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event. In addition, if any files are being dragged,
then one of the types will be the string "<code title="">Files</code>".</p>
</dd>
@@ -76977,7 +77024,7 @@
values must be ignored.</p>
<p>The <dfn id=dom-datatransfer-effectallowed title=dom-DataTransfer-effectAllowed><code>effectAllowed</code></dfn> attribute is
- used in the drag-and-drop processing model to initialize the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute during the <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> and <code title=event-dragover><a href=#event-dragover>dragover</a></code> events.
+ used in the drag-and-drop processing model to initialize the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute during the <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> and <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> events.
When the <code><a href=#datatransfer>DataTransfer</a></code> object is created, the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute is set to a string value. On
getting, it must return its current value. On setting, if <a href=#drag-data-store>drag data store</a>'s <a href=#drag-data-store-mode title="drag data store mode">mode</a> is the <a href=#concept-dnd-rw title=concept-dnd-rw>read/write
mode</a> and the new value is one of "<code title="">none</code>", "<code title="">copy</code>", "<code title="">copyLink</code>", "<code title="">copyMove</code>", "<code title="">link</code>", "<code title="">linkMove</code>", "<code title="">move</code>", "<code title="">all</code>", or "<code title="">uninitialized</code>", then the attribute's current value
@@ -77577,11 +77624,11 @@
<ol><li>
- <p>If <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>, set the
+ <p>If <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>, set the
<a href=#drag-data-store-mode>drag data store mode</a> to the <a href=#concept-dnd-rw title=concept-dnd-rw>read/write
mode</a>.</p>
- <p>If <var title="">e</var> is <code title=event-drop><a href=#event-drop>drop</a></code>, set the <a href=#drag-data-store-mode>drag data
+ <p>If <var title="">e</var> is <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code>, set the <a href=#drag-data-store-mode>drag data
store mode</a> to the <a href=#concept-dnd-ro title=concept-dnd-ro>read-only mode</a>.</p>
</li>
@@ -77595,10 +77642,10 @@
<li>
<p id=dropEffect-initialization>Set the <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attribute to "<code title="">none</code>"
- if <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>, <code title=event-drag><a href=#event-drag>drag</a></code>, <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>, or <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>; to the value corresponding to the <a href=#current-drag-operation>current drag
- operation</a> if <var title="">e</var> is <code title=event-drop><a href=#event-drop>drop</a></code> or <code title=event-dragend><a href=#event-dragend>dragend</a></code>; and to a value based on the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute's value and the
+ if <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>, <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code>, <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>, or <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>; to the value corresponding to the <a href=#current-drag-operation>current drag
+ operation</a> if <var title="">e</var> is <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> or <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>; and to a value based on the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute's value and the
drag-and-drop source, as given by the following table, otherwise (i.e. if <var title="">e</var>
- is <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> or <code title=event-dragover><a href=#event-dragover>dragover</a></code>):</p>
+ is <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> or <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code>):</p>
<table><thead><tr><th><code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code></th>
<th><code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code></th>
@@ -77642,7 +77689,7 @@
<p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> <code><a href=#dragevent>DragEvent</a></code> object
and initialize it to have the given name <var title="">e</var>, to bubble, to be cancelable
- unless <var title="">e</var> is <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code>, <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code>, or <code title=event-dragend><a href=#event-dragend>dragend</a></code>, and to
+ unless <var title="">e</var> is <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code>, <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code>, or <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code>, and to
have the <code title=dom-UIEvent-detail><a href=#dom-uievent-detail>detail</a></code> attribute initialized to zero, the mouse
and key attributes initialized according to the state of the input devices as they would be for
user interaction events, the <code title="">relatedTarget</code> attribute initialized to null,
@@ -77659,7 +77706,7 @@
<code><a href=#dragevent>DragEvent</a></code> object at the specified target element.</li>
<li><p>Set the <a href=#drag-data-store-allowed-effects-state>drag data store allowed effects state</a> to the current value of <var title="">dataTransfer</var>'s <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code>
- attribute. (It can only have changed value if <var title="">e</var> is <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code>.)</li>
+ attribute. (It can only have changed value if <var title="">e</var> is <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code>.)</li>
<li><p>Set the <a href=#drag-data-store-mode>drag data store mode</a> back to the <a href=#concept-dnd-p title=concept-dnd-p>protected mode</a> if it was changed in the first step.</li>
@@ -77858,7 +77905,7 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> at the
<a href=#source-node>source node</a>.</p>
<p>If the event is canceled, then the drag-and-drop operation should not occur; abort these
@@ -77927,7 +77974,7 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-drag><a href=#event-drag>drag</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> at the
<a href=#source-node>source node</a>. If this event is canceled, the user agent must set the <a href=#current-drag-operation>current
drag operation</a> to "<code title="">none</code>" (no drag operation).</p>
@@ -77935,7 +77982,7 @@
<li>
- <p>If the <code title=event-drag><a href=#event-drag>drag</a></code> event was not canceled and the user has not ended
+ <p>If the <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event was not canceled and the user has not ended
the drag-and-drop operation, check the state of the drag-and-drop operation, as follows:</p>
<ol><li>
@@ -77943,7 +77990,7 @@
<p>If the user is indicating a different <a href=#immediate-user-selection>immediate user selection</a> than during the
last iteration (or if this is the first iteration), and if this <a href=#immediate-user-selection>immediate user
selection</a> is not the same as the <a href=#current-target-element>current target element</a>, then <a href=#fire-a-dnd-event>fire a
- DND event</a> named <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code> at the <a href=#current-target-element>current
+ DND event</a> named <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code> at the <a href=#current-target-element>current
target element</a>, and then update the <a href=#current-target-element>current target element</a> as follows:</p>
<dl class=switch><dt>If the new <a href=#immediate-user-selection>immediate user selection</a> is null</dt>
@@ -77960,7 +78007,7 @@
<dd>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at the
<a href=#immediate-user-selection>immediate user selection</a>.</p>
<p>If the event is canceled, then set the <a href=#current-target-element>current target element</a> to the
@@ -77994,7 +78041,7 @@
<p>If the <a href=#immediate-user-selection>immediate user selection</a> is <var title="">new target</var>, then
leave the <a href=#current-target-element>current target element</a> unchanged.</p>
- <p>Otherwise, <a href=#fire-a-dnd-event>fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at <var title="">new target</var>. Then, set the
+ <p>Otherwise, <a href=#fire-a-dnd-event>fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at <var title="">new target</var>. Then, set the
<a href=#current-target-element>current target element</a> to <var title="">new target</var>, regardless of
whether that event was canceled or not.</p>
@@ -78010,7 +78057,7 @@
<dd>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> at
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> at
<a href=#the-body-element-0>the body element</a>, if there is one, or at the <code><a href=#document>Document</a></code> object, if
not. Then, set the <a href=#current-target-element>current target element</a> to <a href=#the-body-element-0>the body element</a>,
regardless of whether that event was canceled or not.</p>
@@ -78025,7 +78072,7 @@
<p>If the previous step caused the <a href=#current-target-element>current target element</a> to change, and if the
previous target element was not null or a part of a non-DOM document, then <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> at the previous target
+ event</a> named <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> at the previous target
element.</p>
</li>
@@ -78033,10 +78080,10 @@
<li>
<p>If the <a href=#current-target-element>current target element</a> is a DOM element, then <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragover><a href=#event-dragover>dragover</a></code> at this <a href=#current-target-element>current target
+ event</a> named <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> at this <a href=#current-target-element>current target
element</a>.</p>
- <p>If the <code title=event-dragover><a href=#event-dragover>dragover</a></code> event is not canceled, run the
+ <p>If the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event is not canceled, run the
appropriate step from the following list:</p>
<dl class=switch><dt>If the <a href=#current-target-element>current target element</a> is a text field (e.g. <code><a href=#the-textarea-element>textarea</a></code>,
@@ -78066,7 +78113,7 @@
<dd><p>Reset the <a href=#current-drag-operation>current drag operation</a> to "<code title="">none</code>".</dd>
- </dl><p>Otherwise (if the <code title=event-dragover><a href=#event-dragover>dragover</a></code> event <em>is</em> canceled),
+ </dl><p>Otherwise (if the <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event <em>is</em> canceled),
set the <a href=#current-drag-operation>current drag operation</a> based on the values of the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> and <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> attributes of the <code><a href=#dragevent>DragEvent</a></code>
object's <code title=dom-DragEvent-dataTransfer><a href=#dom-dragevent-datatransfer>dataTransfer</a></code> object as they stood
after the event <a href=#concept-event-dispatch title=concept-event-dispatch>dispatch</a> finished, as per the
@@ -78118,7 +78165,7 @@
<li>
<p>Otherwise, if the user ended the drag-and-drop operation (e.g. by releasing the mouse button
- in a mouse-driven drag-and-drop interface), or if the <code title=event-drag><a href=#event-drag>drag</a></code> event
+ in a mouse-driven drag-and-drop interface), or if the <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event
was canceled, then this will be the last iteration. Run the following steps, then stop the
drag-and-drop operation:</p>
@@ -78132,7 +78179,7 @@
<ol><li><p>Let <var title="">dropped</var> be false.</li>
<li><p>If the <a href=#current-target-element>current target element</a> is a DOM element, <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> at it; otherwise, if it is
+ event</a> named <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> at it; otherwise, if it is
not null, use platform-specific conventions for drag cancellation.</li>
<li><p>Set the <a href=#current-drag-operation>current drag operation</a> to "<code title="">none</code>".</li>
@@ -78142,7 +78189,7 @@
<ol><li><p>Let <var title="">dropped</var> be true.</li>
<li><p>If the <a href=#current-target-element>current target element</a> is a DOM element, <a href=#fire-a-dnd-event>fire a DND
- event</a> named <code title=event-drop><a href=#event-drop>drop</a></code> at it; otherwise, use
+ event</a> named <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> at it; otherwise, use
platform-specific conventions for indicating a drop.</li>
<li>
@@ -78182,14 +78229,14 @@
<li>
- <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dragend><a href=#event-dragend>dragend</a></code> at the
+ <p><a href=#fire-a-dnd-event>Fire a DND event</a> named <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> at the
<a href=#source-node>source node</a>.</p>
</li>
<li>
- <p>Run the appropriate steps from the following list as the default action of the <code title=event-dragend><a href=#event-dragend>dragend</a></code> event:</p>
+ <p>Run the appropriate steps from the following list as the default action of the <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event:</p>
<dl class=switch><dt>If <var title="">dropped</var> is true, the <a href=#current-target-element>current target element</a> is a
<i>text field</i> (see below), the <a href=#current-drag-operation>current drag operation</a> is "<code title="">move</code>", and the source of the drag-and-drop operation is a selection in the
@@ -78259,7 +78306,7 @@
<!-- <th> <code title="dom-DataTransfer-effectAllowed">effectAllowed</code> </th> -->
<th> <code title=dom-DataTransfer-dropEffect><a href=#dom-datatransfer-dropeffect>dropEffect</a></code> </th>
<th> Default Action </th>
- <tbody><tr><td><dfn id=event-dragstart title=event-dragstart><code>dragstart</code></dfn></td>
+ <tbody><tr><td><dfn id=event-dnd-dragstart title=event-dnd-dragstart><code>dragstart</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78267,7 +78314,7 @@
<!-- <td>"<code title="">uninitialized</code>"</td> -->
<td>"<code title="">none</code>"</td>
<td>Initiate the drag-and-drop operation</td>
- <tr><td><dfn id=event-drag title=event-drag><code>drag</code></dfn></td>
+ <tr><td><dfn id=event-dnd-drag title=event-dnd-drag><code>drag</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78275,7 +78322,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>Continue the drag-and-drop operation</td>
- <tr><td><dfn id=event-dragenter title=event-dragenter><code>dragenter</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragenter title=event-dnd-dragenter><code>dragenter</code></dfn></td>
<td><a href=#immediate-user-selection>Immediate user selection</a> or <a href=#the-body-element-0>the body element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78283,7 +78330,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#dropEffect-initialization>Based on <code>effectAllowed</code> value</a></td>
<td>Reject <a href=#immediate-user-selection>immediate user selection</a> as potential <a href=#current-target-element title="current target element">target element</a></td>
- <tr><td><dfn id=event-dragexit title=event-dragexit><code>dragexit</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragexit title=event-dnd-dragexit><code>dragexit</code></dfn></td>
<td><a href=#current-target-element title="current target element">Previous target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78291,7 +78338,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>None</td>
- <tr><td><dfn id=event-dragleave title=event-dragleave><code>dragleave</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragleave title=event-dnd-dragleave><code>dragleave</code></dfn></td>
<td><a href=#current-target-element title="current target element">Previous target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78299,7 +78346,7 @@
<!-- <td>Same as last event</td> -->
<td>"<code title="">none</code>"</td>
<td>None</td>
- <tr><td><dfn id=event-dragover title=event-dragover><code>dragover</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragover title=event-dnd-dragover><code>dragover</code></dfn></td>
<td><a href=#current-target-element>Current target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78307,7 +78354,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#dropEffect-initialization>Based on <code>effectAllowed</code> value</a></td>
<td>Reset the <a href=#current-drag-operation>current drag operation</a> to "none"</td>
- <tr><td><dfn id=event-drop title=event-drop><code>drop</code></dfn></td>
+ <tr><td><dfn id=event-dnd-drop title=event-dnd-drop><code>drop</code></dfn></td>
<td><a href=#current-target-element>Current target element</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -78315,7 +78362,7 @@
<!-- <td>Same as last event</td> -->
<td><a href=#current-drag-operation>Current drag operation</a></td>
<td>Varies</td>
- <tr><td><dfn id=event-dragend title=event-dragend><code>dragend</code></dfn></td>
+ <tr><td><dfn id=event-dnd-dragend title=event-dnd-dragend><code>dragend</code></dfn></td>
<td><a href=#source-node>Source node</a></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -78324,7 +78371,7 @@
<td><a href=#current-drag-operation>Current drag operation</a></td>
<td>Varies</td>
</table><p>Not shown in the above table: all these events bubble, and the <code title=dom-DataTransfer-effectAllowed><a href=#dom-datatransfer-effectallowed>effectAllowed</a></code> attribute always has the value it had
- after the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event, defaulting to "<code title="">uninitialized</code>" in the <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event.</p>
+ after the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event, defaulting to "<code title="">uninitialized</code>" in the <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event.</p>
@@ -78623,8 +78670,8 @@
the user agent should then follow the relevant platform-specific conventions for copy operations
(e.g. updating the clipboard).</p>
- <p>The events involved in this process are the <code title="event-dragstart">dragstart</code>,
- <code title="event-drag">drag</code>, and <code title="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragstart">dragstart</code>,
+ <code title="event-dnd-drag">drag</code>, and <code title="event-dnd-dragend">dragend</code> events.</p>
<h5>Cut to clipboard</h5>
@@ -78633,8 +78680,8 @@
copy operation (see the previous section), followed, if the copy was completed successfully, by <a
href="#contenteditable-delete">a selection delete operation</a>.</p>
- <p>The events involved in this process are the <code title="event-dragstart">dragstart</code>,
- <code title="event-drag">drag</code>, and <code title="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragstart">dragstart</code>,
+ <code title="event-dnd-drag">drag</code>, and <code title="event-dnd-dragend">dragend</code> events.</p>
<h5>Paste from clipboard</h5>
@@ -78647,9 +78694,9 @@
selection</span>) the element with the keyboard focus, and then ended the drag-and-drop operation
without canceling it.</p>
- <p>The events involved in this process are the <code title="event-dragenter">dragenter</code>,
- <code title="event-dragover">dragover</code>, <code title="event-dragexit">dragexit</code>, <code
- title="event-dragleave">dragleave</code>, and <code title="event-drop">drop</code> events.</p>
+ <p>The events involved in this process are the <code title="event-dnd-dragenter">dragenter</code>,
+ <code title="event-dnd-dragover">dragover</code>, <code title="event-dnd-dragexit">dragexit</code>, <code
+ title="event-dnd-dragleave">dragleave</code>, and <code title="event-dnd-drop">drop</code> events.</p>
<h5>Paste from selection</h5>
@@ -78671,13 +78718,13 @@
<h4 id=security-risks-in-the-drag-and-drop-model><span class=secno>8.7.9 </span>Security risks in the drag-and-drop model</h4>
<p>User agents must not make the data added to the <code><a href=#datatransfer>DataTransfer</a></code> object during the
- <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event available to scripts until the <code title=event-drop><a href=#event-drop>drop</a></code> event, because otherwise, if a user were to drag sensitive
+ <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event available to scripts until the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event, because otherwise, if a user were to drag sensitive
information from one document to a second document, crossing a hostile third document in the
process, the hostile document could intercept the data.</p>
<p>For the same reason, user agents must consider a drop to be successful only if the user
specifically ended the drag operation — if any scripts end the drag operation, it must be
- considered unsuccessful (canceled) and the <code title=event-drop><a href=#event-drop>drop</a></code> event must not be
+ considered unsuccessful (canceled) and the <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event must not be
fired.</p>
<p>User agents should take care to not start drag-and-drop operations in response to script
@@ -78710,13 +78757,13 @@
- <h3 id=event-definitions-2><span class=secno>9.1 </span>Event definitions</h3>
+ <h3 id=the-messageevent-interfaces><span class=secno>9.1 </span>The <code><a href=#messageevent>MessageEvent</a></code> interfaces</h3>
<p>Messages in <a href=#server-sent-events>server-sent events</a>, <a href=#network>Web sockets</a>, <a href=#web-messaging>cross-document
- messaging</a>, <a href=#channel-messaging>channel messaging</a>, and <a href=#broadcasting-to-other-browsing-contexts>broadcast channels</a> use the <dfn id=event-message title=event-message><code>message</code></dfn> event. </p>
+ messaging</a>, <a href=#channel-messaging>channel messaging</a>, and <a href=#broadcasting-to-other-browsing-contexts>broadcast channels</a> use the
+ <code><a href=#messageevent>MessageEvent</a></code> interface for their <code title=event-message><a href=#event-message>message</a></code>
+ events:</p>
- <p>The following interface is defined for this event:</p>
-
<pre class=idl>[Constructor(DOMString type, optional <a href=#messageeventinit>MessageEventInit</a> eventInitDict)]
interface <dfn id=messageevent>MessageEvent</dfn> : <a href=#event>Event</a> {
readonly attribute any <a href=#dom-messageevent-data title=dom-MessageEvent-data>data</a>;
@@ -78774,8 +78821,9 @@
<dd>
+<!--CLEANUP-->
<p>Returns the <code><a href=#windowproxy>WindowProxy</a></code> of the source window, for <a href=#web-messaging>cross-document
- messaging</a>, and the <code><a href=#messageport>MessagePort</a></code> being attached, in the <code title=event-connect>connect</code> event fired at <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
+ messaging</a>, and the <code><a href=#messageport>MessagePort</a></code> being attached, in the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> event fired at <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
objects.</p>
</dd>
@@ -78813,7 +78861,7 @@
value it was initialized to. When the object is created, this attribute must be initialized to
null. It represents, in <a href=#web-messaging>cross-document messaging</a>, the <code><a href=#windowproxy>WindowProxy</a></code> of the
<a href=#browsing-context>browsing context</a> of the <code><a href=#window>Window</a></code> object from which the message came; and
- in the <code title=event-connect>connect</code> events used by <a href=#sharedworkerglobalscope title=SharedWorkerGlobalScope>shared workers</a>, the newly connecting
+ in the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> events used by <a href=#sharedworkerglobalscope title=SharedWorkerGlobalScope>shared workers</a>, the newly connecting
<code><a href=#messageport>MessagePort</a></code>.</p>
<p>The <dfn id=dom-messageevent-ports title=dom-MessageEvent-ports><code>ports</code></dfn> attribute must return the
@@ -79000,9 +79048,9 @@
interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-eventsource-onopen title=handler-EventSource-onopen><code>onopen</code></dfn> <td> <code title=event-open>open</code>
+ <tbody><tr><td><dfn id=handler-eventsource-onopen title=handler-EventSource-onopen><code>onopen</code></dfn> <td> <code title=event-open><a href=#event-open>open</a></code>
<tr><td><dfn id=handler-eventsource-onmessage title=handler-EventSource-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-eventsource-onerror title=handler-EventSource-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tr><td><dfn id=handler-eventsource-onerror title=handler-EventSource-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
</table><hr><p>In addition to the above, each <code><a href=#eventsource>EventSource</a></code> object has the following associated
with it:</p>
@@ -79090,7 +79138,7 @@
<hr><p>When a user agent is to <dfn id=announce-the-connection>announce the connection</dfn>, the user agent must <a href=#queue-a-task>queue a
task</a> which, if the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute is
set to a value other than <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code>, sets the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-OPEN><a href=#dom-eventsource-open>OPEN</a></code> and <a href=#fire-a-simple-event title="fire a simple event">fires a simple
- event</a> named <code title=event-open>open</code> at the <code><a href=#eventsource>EventSource</a></code>
+ event</a> named <code title=event-open><a href=#event-open>open</a></code> at the <code><a href=#eventsource>EventSource</a></code>
object.</p>
<p>When a user agent is to <dfn id=reestablish-the-connection>reestablish the connection</dfn>, the user agent must run the
@@ -79106,7 +79154,7 @@
<li><p>Set the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-CONNECTING><a href=#dom-eventsource-connecting>CONNECTING</a></code>.</li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-error>error</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the
<code><a href=#eventsource>EventSource</a></code> object.</li>
</ol></li>
@@ -79139,7 +79187,7 @@
</ol><p>When a user agent is to <dfn id=fail-the-connection>fail the connection</dfn>, the user agent must <a href=#queue-a-task>queue a
task</a> which, if the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute is
set to a value other than <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code>, sets the <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> attribute to <code title=dom-EventSource-CLOSED><a href=#dom-eventsource-closed>CLOSED</a></code> and <a href=#fire-a-simple-event title="fire a simple event">fires a simple
- event</a> named <code title=event-error>error</code> at the <code><a href=#eventsource>EventSource</a></code> object.
+ event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <code><a href=#eventsource>EventSource</a></code> object.
<strong>Once the user agent has <a href=#fail-the-connection title="fail the connection">failed the connection</a>, it
does <em>not</em> attempt to reconnect!</strong></p>
@@ -79498,13 +79546,13 @@
<h4 id=garbage-collection-0><span class=secno>9.2.8 </span>Garbage collection</h4>
<p>While an <code><a href=#eventsource>EventSource</a></code> object's <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> is <code title=dom-EventSource-CONNECTING><a href=#dom-eventsource-connecting>CONNECTING</a></code>, and the object has one or more event
- listeners registered for <code title=event-open>open</code>, <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error>error</code> events, there must
+ listeners registered for <code title=event-open><a href=#event-open>open</a></code>, <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error><a href=#event-error>error</a></code> events, there must
be a strong reference from the <code><a href=#window>Window</a></code> or <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object that
the <code><a href=#eventsource>EventSource</a></code> object's constructor was invoked from to the <code><a href=#eventsource>EventSource</a></code>
object itself.</p>
<p>While an <code><a href=#eventsource>EventSource</a></code> object's <code title=dom-EventSource-readyState><a href=#dom-eventsource-readystate>readyState</a></code> is <code title=dom-EventSource-OPEN><a href=#dom-eventsource-open>OPEN</a></code>, and the object has one or more event listeners
- registered for <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error>error</code> events, there must be a strong reference from the
+ registered for <code title=event-message><a href=#event-message>message</a></code> or <code title=event-error><a href=#event-error>error</a></code> events, there must be a strong reference from the
<code><a href=#window>Window</a></code> or <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object that the <code><a href=#eventsource>EventSource</a></code>
object's constructor was invoked from to the <code><a href=#eventsource>EventSource</a></code> object itself.</p>
@@ -79544,7 +79592,7 @@
parsed, and so forth.</p>
<p>Implementations are especially encouraged to report detailed information to their development
- consoles whenever an <code title=event-error>error</code> event is fired, since little to no
+ consoles whenever an <code title=event-error><a href=#event-error>error</a></code> event is fired, since little to no
information can be made available in the events themselves.</p>
@@ -79782,7 +79830,7 @@
<p class=note>If the <i><a href=#establish-a-websocket-connection>establish a WebSocket connection</a></i> algorithm fails, it triggers the
<i><a href=#fail-the-websocket-connection>fail the WebSocket connection</a></i> algorithm, which then invokes the <i><a href=#close-the-websocket-connection>close the WebSocket
connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the WebSocket connection is closed</a></i>,
- which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as
+ which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as
described below</a>.</p>
</li>
@@ -79864,7 +79912,7 @@
<p>Do nothing.</p>
<p class=note>The connection is already closing or is already closed. If it has not already,
- a <code title=event-socket-close>close</code> event will eventually fire <a href=#closeWebSocket>as described below</a>.</p>
+ a <code title=event-close><a href=#event-close>close</a></code> event will eventually fire <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -79878,7 +79926,7 @@
<p class=note>The <i><a href=#fail-the-websocket-connection>fail the WebSocket connection</a></i> algorithm invokes the <i><a href=#close-the-websocket-connection>close the
WebSocket connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the WebSocket connection is
- closed</a></i>, which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as described below</a>.</p>
+ closed</a></i>, which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -79899,7 +79947,7 @@
<p class=note>The <i><a href=#start-the-websocket-closing-handshake>start the WebSocket closing handshake</a></i> algorithm eventually invokes
the <i><a href=#close-the-websocket-connection>close the WebSocket connection</a></i> algorithm, which then establishes that <i><a href=#the-websocket-connection-is-closed>the
- WebSocket connection is closed</a></i>, which fires the <code title=event-socket-close>close</code> event <a href=#closeWebSocket>as described
+ WebSocket connection is closed</a></i>, which fires the <code title=event-close><a href=#event-close>close</a></code> event <a href=#closeWebSocket>as described
below</a>.</p>
</dd>
@@ -79913,7 +79961,7 @@
<p class=note><i><a href=#the-websocket-closing-handshake-is-started>The WebSocket closing handshake is started</a></i>, and will eventually invoke
the <i><a href=#close-the-websocket-connection>close the WebSocket connection</a></i> algorithm, which will establish that <i><a href=#the-websocket-connection-is-closed>the
- WebSocket connection is closed</a></i>, and thus the <code title=event-socket-close>close</code>
+ WebSocket connection is closed</a></i>, and thus the <code title=event-close><a href=#event-close>close</a></code>
event will fire, <a href=#closeWebSocket>as described below</a>.</p>
</dd>
@@ -80064,10 +80112,10 @@
by all objects implementing the <code><a href=#websocket>WebSocket</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-websocket-onopen title=handler-WebSocket-onopen><code>onopen</code></dfn> <td> <code title=event-open>open</code>
+ <tbody><tr><td><dfn id=handler-websocket-onopen title=handler-WebSocket-onopen><code>onopen</code></dfn> <td> <code title=event-open><a href=#event-open>open</a></code>
<tr><td><dfn id=handler-websocket-onmessage title=handler-WebSocket-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-websocket-onerror title=handler-WebSocket-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
- <tr><td><dfn id=handler-websocket-onclose title=handler-WebSocket-onclose><code>onclose</code></dfn> <td> <code title=event-socket-close>close</code>
+ <tr><td><dfn id=handler-websocket-onerror title=handler-WebSocket-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+ <tr><td><dfn id=handler-websocket-onclose title=handler-WebSocket-onclose><code>onclose</code></dfn> <td> <code title=event-close><a href=#event-close>close</a></code>
</table><h4 id=feedback-from-the-protocol><span class=secno>9.3.3 </span>Feedback from the protocol</h4>
<p>When <i><a href=#the-websocket-connection-is-established>the WebSocket connection is established</a></i>, the user agent must <a href=#queue-a-task>queue a
@@ -80091,7 +80139,7 @@
set-cookie-string</a> consisting of the <i><a href="#cookies-set-during-the-server's-opening-handshake">cookies set during the server's opening
handshake</a></i>, for the URL <var title="">url</var> given to the <code title=dom-WebSocket><a href=#dom-websocket>WebSocket()</a></code> constructor. <a href=#refsCOOKIES>[COOKIES]</a> <a href=#refsRFC3629>[RFC3629]</a> <a href=#refsWSP>[WSP]</a></li>
- <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-open>open</code> at the
+ <li><p><a href=#fire-a-simple-event>Fire a simple event</a> named <code title=event-open><a href=#event-open>open</a></code> at the
<code><a href=#websocket>WebSocket</a></code> object.</p>
</ol><hr><p>When <i><a href=#a-websocket-message-has-been-received>a WebSocket message has been received</a></i> with type <var title="">type</var> and data
@@ -80179,7 +80227,7 @@
object. <a href=#refsWSP>[WSP]</a></li>
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#closeevent>CloseEvent</a></code> interface, with the event type <code title=event-socket-close>close</code>, which does not bubble, is not cancelable, has no default
+ <code><a href=#closeevent>CloseEvent</a></code> interface, with the event type <code title=event-close><a href=#event-close>close</a></code>, which does not bubble, is not cancelable, has no default
action, whose <code title=dom-CloseEvent-wasClean><a href=#dom-closeevent-wasclean>wasClean</a></code> attribute is initialized to
true if the connection closed <i title="">cleanly</i> and false otherwise, whose <code title=dom-CloseEvent-code><a href=#dom-closeevent-code>code</a></code> attribute is initialized to <i><a href=#the-websocket-connection-close-code>the WebSocket connection
close code</a></i>, and whose <code title=dom-CloseEvent-reason><a href=#dom-closeevent-reason>reason</a></code> attribute is
@@ -80294,7 +80342,7 @@
<li><p>Return <var title="">host</var>, <var title="">port</var>, <var title="">resource
name</var>, and <var title="">secure</var>.</li>
- </ol><h4 id=event-definitions-3><span class=secno>9.3.6 </span>Event definitions</h4>
+ </ol><h4 id=the-closeevent-interfaces><span class=secno>9.3.6 </span>The <code><a href=#closeevent>CloseEvent</a></code> interfaces</h4>
<pre class=idl>[Constructor(DOMString type, optional <a href=#closeeventinit>CloseEventInit</a> eventInitDict)]
interface <dfn id=closeevent>CloseEvent</dfn> : <a href=#event>Event</a> {
@@ -80328,18 +80376,18 @@
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-CONNECTING><a href=#dom-websocket-connecting>CONNECTING</a></code> (0) as of
the last time the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must not be garbage collected if there are any event listeners
- registered for <code title=event-open>open</code> events, <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error>error</code> events, or
- <code title=event-socket-close>close</code> events.</p>
+ registered for <code title=event-open><a href=#event-open>open</a></code> events, <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error><a href=#event-error>error</a></code> events, or
+ <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-OPEN><a href=#dom-websocket-open>OPEN</a></code> (1) as of the last time
the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must not be
- garbage collected if there are any event listeners registered for <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error>error</code>, or <code title=event-socket-close>close</code> events.</p>
+ garbage collected if there are any event listeners registered for <code title=event-message><a href=#event-message>message</a></code> events, <code title=event-error><a href=#event-error>error</a></code>, or <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object whose <code title=dom-WebSocket-readyState><a href=#dom-websocket-readystate>readyState</a></code>
attribute's value was set to <code title=dom-WebSocket-CLOSING><a href=#dom-websocket-closing>CLOSING</a></code> (2) as of the last
time the <a href=#event-loop>event loop</a> started executing a <a href=#concept-task title=concept-task>task</a> must
- not be garbage collected if there are any event listeners registered for <code title=event-error>error</code> or <code title=event-socket-close>close</code> events.</p>
+ not be garbage collected if there are any event listeners registered for <code title=event-error><a href=#event-error>error</a></code> or <code title=event-close><a href=#event-close>close</a></code> events.</p>
<p>A <code><a href=#websocket>WebSocket</a></code> object with <i title="the WebSocket connection is established"><a href=#the-websocket-connection-is-established>an
established connection</a></i> that has data queued to be transmitted to the network must not be
@@ -80794,7 +80842,7 @@
<code><a href=#the-iframe-element>iframe</a></code> to receive a <code title=event-hashchange><a href=#event-hashchange>hashchange</a></code> event.</li>
<li>Resize the <code><a href=#the-iframe-element>iframe</a></code>, causing the <code><a href=#window>Window</a></code> in the <code><a href=#the-iframe-element>iframe</a></code> to
- receive a <code title=event-resize>resize</code> event.</li>
+ receive a <code title=event-resize><a href=#event-resize>resize</a></code> event.</li>
<!-- anything else? -->
@@ -81065,7 +81113,7 @@
<li><p>If <var title="">original port</var> is <a href=#related-to-an-ill-fated-port>related to an ill-fated port</a>, then
create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a
- simple event</a> named <code title=event-error>error</code> at the <var title="">new
+ simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at the <var title="">new
port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message
queue</a> of <var title="">new port</var>. The <a href=#concept-task title=concept-task>task</a> must
be associated with the <a href=#responsible-document>responsible document</a> specified by <var title="">new
@@ -81318,7 +81366,7 @@
port</dfn>.</li>
<!--CLEANUP-->
- <li><p>Create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a simple event</a> named <code title=event-error>error</code> at <var title="">target port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message queue</a> of <var title="">target port</var>. The <a href=#concept-task title=concept-task>task</a> must be associated with the <a href=#responsible-document>responsible document</a>
+ <li><p>Create a <a href=#concept-task title=concept-task>task</a> that <a href=#fire-a-simple-event title="fire a simple event">fires a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at <var title="">target port</var>, and add the <a href=#concept-task title=concept-task>task</a> to the <a href=#port-message-queue>port message queue</a> of <var title="">target port</var>. The <a href=#concept-task title=concept-task>task</a> must be associated with the <a href=#responsible-document>responsible document</a>
specified by <var title="">source port</var>'s <a href=#concept-port-owner title=concept-port-owner>owner</a>.</li>
<li><p>Disentangle the two ports.</li>
@@ -81335,7 +81383,7 @@
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
<tbody><tr><td><dfn id=handler-messageport-onmessage title=handler-MessagePort-onmessage><code>onmessage</code></dfn> <td> <code title=event-message><a href=#event-message>message</a></code>
- <tr><td><dfn id=handler-messageport-onerror title=handler-MessagePort-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tr><td><dfn id=handler-messageport-onerror title=handler-MessagePort-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
</table><p>The first time a <code><a href=#messageport>MessagePort</a></code> object's <code title=handler-MessagePort-onmessage><a href=#handler-messageport-onmessage>onmessage</a></code> IDL attribute is set, the port's <a href=#port-message-queue>port
message queue</a> must be enabled, as if the <code title=dom-MessagePort-start><a href=#dom-messageport-start>start()</a></code>
method had been called.</p>
@@ -82678,7 +82726,8 @@
worker.port.postMessage('some message');
worker.port.postMessage({ foo: 'structured', bar: ['data', 'also', 'possible']});</pre>
- <p>Inside the shared worker, new clients of the worker are announced using the <code title=event-connect>connect</code> event. The port for the new client is given by the event
+<!--CLEANUP-->
+ <p>Inside the shared worker, new clients of the worker are announced using the <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> event. The port for the new client is given by the event
object's <code title=dom-messageevent-source><a href=#dom-messageevent-source>source</a></code> attribute.</p>
<pre>onconnect = function (event) {
@@ -82738,7 +82787,7 @@
<!-- v2-onclose (remember to specify the task source, too)
<li><p><span>Queue a task</span> to <span>fire a simple event</span> named <code
- title="event-worker-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
+ title="event-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
-->
<li><p>Set the worker's <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag to true. (This prevents any further
@@ -82749,7 +82798,7 @@
by objects implementing the <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><!-- v2-onclose <tr><td><dfn title="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code title="event-worker-close">close</code> --><tr><td><dfn id=handler-workerglobalscope-onerror title=handler-WorkerGlobalScope-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
+ <tbody><!-- v2-onclose <tr><td><dfn title="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code title="event-close">close</code> --><tr><td><dfn id=handler-workerglobalscope-onerror title=handler-WorkerGlobalScope-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
<tr><td><dfn id=handler-workerglobalscope-onoffline title=handler-WorkerGlobalScope-onoffline><code>onoffline</code></dfn> <td> <code title=event-offline><a href=#event-offline>offline</a></code> <!-- new -->
<tr><td><dfn id=handler-workerglobalscope-ononline title=handler-WorkerGlobalScope-ononline><code>ononline</code></dfn> <td> <code title=event-online><a href=#event-online>online</a></code> <!-- new -->
</table><hr><!--CLEANUP--><p class=note>For <a href=#data-protocol title="data protocol"><code title="">data:</code> URLs</a>, this is
@@ -82817,7 +82866,7 @@
JavaScript</a> if the <a href=#javascript-global-environment>JavaScript global environment</a> is a <a href=#shared-worker-environment>shared worker
environment</a>.</p>
- <p>Shared workers receive message ports through <code title=event-WorkerGlobalScope-connect>connect</code> events on their <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code> object for each
+ <p>Shared workers receive message ports through <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code> events on their <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code> object for each
connection.</p>
<p>The <dfn id=dom-sharedworkerglobalscope-name title=dom-SharedWorkerGlobalScope-name><code>name</code></dfn> attribute must return
@@ -82831,7 +82880,7 @@
interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-sharedworkerglobalscope-onconnect title=handler-SharedWorkerGlobalScope-onconnect><code>onconnect</code></dfn> <td> <code title=event-connect>connect</code>
+ <tbody><tr><td><dfn id=handler-sharedworkerglobalscope-onconnect title=handler-SharedWorkerGlobalScope-onconnect><code>onconnect</code></dfn> <td> <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>
</table><p>For the purposes of the <a href=#application-cache>application cache</a> networking model, a shared worker is its
own <a href=#cache-host>cache host</a>. The <a href=#run-a-worker>run a worker</a> algorithm takes care of associating the
worker with an <a href=#application-cache>application cache</a>.</p>
@@ -82959,7 +83008,7 @@
<p>If the attempt fails, then for each <code><a href=#worker>Worker</a></code> or <code><a href=#sharedworker>SharedWorker</a></code> object
associated with <var title="">worker global scope</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
- a simple event</a> named <code title=event-error>error</code> at that object. Abort these
+ a simple event</a> named <code title=event-error><a href=#event-error>error</a></code> at that object. Abort these
steps.</p>
<p>If the attempt succeeds, then let <var title="">source</var> be the result of running the
@@ -83006,7 +83055,7 @@
no later than it stops being a <a href=#permissible-worker>permissible worker</a>, <var title="">worker global
scope</var>'s <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag is set to true<!--
v2-onclose and <span title="queue a task">a task is queued</span> to <span>fire a simple
- event</span> named <code title="event-worker-close">close</code> at <var title="">worker global
+ event</span> named <code title="event-close">close</code> at <var title="">worker global
scope</var>-->.</p>
</li>
@@ -83072,7 +83121,7 @@
<p>For each <code>Worker</code> or <code>SharedWorker</code> object associated with <var
title="">worker global scope</var>, <span>queue a task</span> to <span>fire a simple
- event</span> named <code title="event-worker-close">close</code> at that object.</p>
+ event</span> named <code title="event-close">close</code> at that object.</p>
</li>
-->
@@ -83091,32 +83140,32 @@
<ol><!-- v2-onclose
<li><p>If the worker's <code>WorkerGlobalScope</code> object's <span
title="dom-WorkerGlobalScope-closing">closing</span> flag is false, <span>queue a task</span> to
- <span>fire a simple event</span> named <code title="event-worker-close">close</code> at the
+ <span>fire a simple event</span> named <code title="event-close">close</code> at the
worker's <code>WorkerGlobalScope</code> object.</p></li>
--><li><p>Set the worker's <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#dom-workerglobalscope-closing title=dom-WorkerGlobalScope-closing>closing</a> flag to true.</li>
<!-- v2-onclose
<li><p>Wait a user-agent-defined amount of time. If the "<span>run a worker</span>" processing
model defined above immediately starts running event listeners registered for the <code
- title="event-worker-close">close</code> event, this time should not be zero — the idea is
- that the <code title="event-worker-close">close</code> event can be used to clean up when
+ title="event-close">close</code> event, this time should not be zero — the idea is
+ that the <code title="event-close">close</code> event can be used to clean up when
shutting down unexpectedly.</p></li>
-->
<li><p>If there are any <a href=#concept-task title=concept-task>tasks</a> queued in the
<code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object's <a href=#event-loop>event loop</a>'s <a href=#task-queue title="task queue">task
- queues</a><!-- v2-onclose other than the <code title="event-worker-close">close</code> event
+ queues</a><!-- v2-onclose other than the <code title="event-close">close</code> event
that this algorithm just added-->, discard them without processing them.</li>
<!-- v2-onclose
- <li><p>If the <code title="event-worker-close">close</code> event that this algorithm just queued
+ <li><p>If the <code title="event-close">close</code> event that this algorithm just queued
hasn't yet been dispatched, then abort the script currently running in the worker.</p></li>
-->
<li><p>Wait a user-agent-defined amount of time.</li>
<li><p>Abort the script currently running in the worker<!-- v2-onclose (if any script is running,
- then it will be a handler for the <code title="event-worker-close">close</code>
+ then it will be a handler for the <code title="event-close">close</code>
event)-->.</li>
</ol><p>User agents may invoke the "<a href=#kill-a-worker>kill a worker</a>" processing model on a worker at any
@@ -83160,7 +83209,7 @@
<p>For dedicated workers, if the error is still <i title=concept-error-nothandled><a href=#concept-error-nothandled>not
handled</a></i> afterwards, the user
agent must <a href=#queue-a-task>queue a task</a> to <a href=#concept-event-fire title=concept-event-fire>fire</a> a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the <code><a href=#errorevent>ErrorEvent</a></code>
- interface, with the name <code title=event-error>error</code>, that doesn't bubble and is
+ interface, with the name <code title=event-error><a href=#event-error>error</a></code>, that doesn't bubble and is
cancelable, with its <code title=dom-ErrorEvent-message><a href=#dom-errorevent-message>message</a></code>, <code title=dom-ErrorEvent-filename><a href=#dom-errorevent-filename>filename</a></code>, <code title=dom-ErrorEvent-lineno><a href=#dom-errorevent-lineno>lineno</a></code>, <code title=dom-ErrorEvent-colno><a href=#dom-errorevent-colno>colno</a></code>,
attributes initialized appropriately,
and with the <code title=dom-ErrorEvent-error><a href=#dom-errorevent-error>error</a></code> attribute initialized to null,
@@ -83171,7 +83220,7 @@
<p>If the implicit port connecting the worker to its <code><a href=#worker>Worker</a></code> object has been
disentangled (i.e. if the parent worker has been terminated), then the user agent must act as if
- the <code><a href=#worker>Worker</a></code> object had no <code title=event-error>error</code> event handler and as
+ the <code><a href=#worker>Worker</a></code> object had no <code title=event-error><a href=#event-error>error</a></code> event handler and as
if that worker's <code title=handler-WorkerGlobalScope-onerror><a href=#handler-workerglobalscope-onerror>onerror</a></code> attribute was
null, but must otherwise act as described above.</p>
@@ -83199,8 +83248,8 @@
objects implementing the <code><a href=#abstractworker>AbstractWorker</a></code> interface:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-abstractworker-onerror title=handler-AbstractWorker-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
-<!-- v2-onclose <tr><td><dfn title="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code title="event-worker-close">close</code> -->
+ <tbody><tr><td><dfn id=handler-abstractworker-onerror title=handler-AbstractWorker-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
+<!-- v2-onclose <tr><td><dfn title="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code title="event-close">close</code> -->
</table><h5 id=script-settings-for-workers><span class=secno>10.2.6.2 </span>Script settings for workers</h5>
<!--CLEANUP-->
@@ -83576,8 +83625,9 @@
<li><p><a href=#entangle>Entangle</a> <var title="">outside port</var>
and <var title="">inside port</var>.</li>
+<!--CLEANUP-->
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-connect>connect</code>, which does not bubble, is not cancelable, has no
+ <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>, which does not bubble, is not cancelable, has no
default action, has a <code title=dom-MessageEvent-data><a href=#dom-messageevent-data>data</a></code> attribute whose value
is initialized to the empty string, has a <code title=dom-MessageEvent-ports><a href=#dom-messageevent-ports>ports</a></code>
attribute whose value is initialized to a <a href=#dfn-read-only-array title=dfn-read-only-array>read only</a>
@@ -83634,8 +83684,9 @@
<li><p>Return <var title="">worker</var> and perform the remaining steps asynchronously.</li>
+<!--CLEANUP-->
<li><p>Create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event that uses the
- <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-connect>connect</code>,
+ <code><a href=#messageevent>MessageEvent</a></code> interface, with the name <code title=event-WorkerGlobalScope-connect><a href=#event-workerglobalscope-connect>connect</a></code>,
which does not bubble, is not cancelable, has no default action, has a <code title=dom-MessageEvent-data><a href=#dom-messageevent-data>data</a></code> attribute whose value is initialized to the empty
string, has a <code title=dom-MessageEvent-ports><a href=#dom-messageevent-ports>ports</a></code> attribute whose value is
initialized to a <a href=#dfn-read-only-array title=dfn-read-only-array>read only</a> array containing only the
@@ -84127,7 +84178,8 @@
<h4 id=the-storage-event><span class=secno>11.2.4 </span>The <code title=event-storage><a href=#event-storage>storage</a></code> event</h4>
- <p>The <dfn id=event-storage title=event-storage><code>storage</code></dfn> event is fired on a
+<!--CLEANUP-->
+ <p>The <code title=event-storage><a href=#event-storage>storage</a></code> event is fired on a
<code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object when a storage area changes, as described in
the previous two sections (<a href=#sessionStorageEvent>for session storage</a>, <a href=#localStorageEvent>for local storage</a>).</p>
@@ -84159,7 +84211,7 @@
(i.e. session or local).</p>
- <h5 id=event-definition-0><span class=secno>11.2.4.1 </span>Event definition</h5>
+ <h5 id=the-storageevent-interface><span class=secno>11.2.4.1 </span>The <code><a href=#storageevent>StorageEvent</a></code> interface</h5>
<pre class=idl>[Constructor(DOMString type, optional <a href=#storageeventinit>StorageEventInit</a> eventInitDict)]
interface <dfn id=storageevent>StorageEvent</dfn> : <a href=#event>Event</a> {
@@ -92710,7 +92762,7 @@
</ol></li>
- <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-DOMContentLoaded>DOMContentLoaded</code> at the <code><a href=#document>Document</a></code>.</li>
+ <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that bubbles named <code title=event-DOMContentLoaded><a href=#event-domcontentloaded>DOMContentLoaded</a></code> at the <code><a href=#document>Document</a></code>.</li>
<li><p><a href=#spin-the-event-loop>Spin the event loop</a> until the <a href=#set-of-scripts-that-will-execute-as-soon-as-possible>set of scripts that will execute as soon
as possible</a> and the <a href=#list-of-scripts-that-will-execute-in-order-as-soon-as-possible>list of scripts that will execute in order as soon as
@@ -92729,7 +92781,7 @@
<ol><li><p>Set the <a href=#current-document-readiness>current document readiness</a> to "<code title="">complete</code>"<!--
this also fires an event synchronously during the task -->.</li>
- <li><p>If the <code><a href=#document>Document</a></code> is in a <a href=#browsing-context>browsing context</a>, create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event named <code title=event-load>load</code> that does not bubble and is not cancelable and which uses the
+ <li><p>If the <code><a href=#document>Document</a></code> is in a <a href=#browsing-context>browsing context</a>, create a <a href=#concept-events-trusted title=concept-events-trusted>trusted</a> event named <code title=event-load><a href=#event-load>load</a></code> that does not bubble and is not cancelable and which uses the
<code><a href=#event>Event</a></code> interface, and <a href=#concept-event-dispatch title=concept-event-dispatch>dispatch</a> it at
the <code><a href=#document>Document</a></code>'s <code><a href=#window>Window</a></code> object, with <i>target override</i> set to the
<code><a href=#document>Document</a></code> object.</li>
@@ -96919,7 +96971,7 @@
<code><a href=#the-marquee-element>marquee</a></code> element must be <a href=#concept-marquee-off title=concept-marquee-off>turned off</a>.</p>
<p>When a <code><a href=#the-marquee-element>marquee</a></code> element is created, the user agent must <a href=#queue-a-task>queue a task</a>
- to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-start>start</code> at the
+ to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-start>start</code> at the
element.</p>
<hr><p>The <dfn id=attr-marquee-behavior title=attr-marquee-behavior><code>behavior</code></dfn> content attribute on
@@ -97001,14 +97053,14 @@
<p>If the <a href=#marquee-current-loop-index>marquee current loop index</a> is now equal to or greater than the element's
<a href=#marquee-loop-count>marquee loop count</a>, <a href=#concept-marquee-off title=concept-marquee-off>turn off</a> the
<code><a href=#the-marquee-element>marquee</a></code> element and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-finish>finish</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
+ named <code title=event-marquee-finish>finish</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
<p>Otherwise, if the <code title=attr-marquee-behavior><a href=#attr-marquee-behavior>behavior</a></code> attribute is in the
<a href=#attr-marquee-behavior-alternate title=attr-marquee-behavior-alternate>alternate</a> state, then <a href=#queue-a-task>queue a
- task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-bounce>bounce</code>
+ task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-bounce>bounce</code>
at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
- <p>Otherwise, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-start>start</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
+ <p>Otherwise, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-marquee-start>start</code> at the <code><a href=#the-marquee-element>marquee</a></code> element.</p>
</li>
@@ -97017,9 +97069,9 @@
attributes</a>, by <code><a href=#the-marquee-element>marquee</a></code> elements:</p>
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
- <tbody><tr><td><dfn id=handler-marquee-onbounce title=handler-marquee-onbounce><code>onbounce</code></dfn> <td> <code title=event-bounce>bounce</code>
- <tr><td><dfn id=handler-marquee-onfinish title=handler-marquee-onfinish><code>onfinish</code></dfn> <td> <code title=event-finish>finish</code>
- <tr><td><dfn id=handler-marquee-onstart title=handler-marquee-onstart><code>onstart</code></dfn> <td> <code title=event-start>start</code>
+ <tbody><tr><td><dfn id=handler-marquee-onbounce title=handler-marquee-onbounce><code>onbounce</code></dfn> <td> <code title=event-marquee-bounce>bounce</code>
+ <tr><td><dfn id=handler-marquee-onfinish title=handler-marquee-onfinish><code>onfinish</code></dfn> <td> <code title=event-marquee-finish>finish</code>
+ <tr><td><dfn id=handler-marquee-onstart title=handler-marquee-onstart><code>onstart</code></dfn> <td> <code title=event-marquee-start>start</code>
</table><hr><p>The <dfn id=dom-marquee-behavior title=dom-marquee-behavior><code>behavior</code></dfn>, <dfn id=dom-marquee-direction title=dom-marquee-direction><code>direction</code></dfn>, <dfn id=dom-marquee-height title=dom-marquee-height><code>height</code></dfn>, <dfn id=dom-marquee-hspace title=dom-marquee-hspace><code>hspace</code></dfn>, <dfn id=dom-marquee-vspace title=dom-marquee-vspace><code>vspace</code></dfn>, and <dfn id=dom-marquee-width title=dom-marquee-width><code>width</code></dfn> IDL attributes must <a href=#reflect>reflect</a> the
respective content attributes of the same name.</p>
@@ -97099,7 +97151,7 @@
<dd>
- <p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the <code><a href=#frame>frame</a></code> element.</p>
+ <p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#frame>frame</a></code> element.</p>
</dd>
@@ -97149,7 +97201,7 @@
<p>When a <code><a href=#document>Document</a></code> in a <code><a href=#frame>frame</a></code> is marked as <a href=#completely-loaded>completely
loaded</a>, the user agent must <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
- named <code title=event-load>load</code> at the <code><a href=#frame>frame</a></code> element.</p>
+ named <code title=event-load><a href=#event-load>load</a></code> at the <code><a href=#frame>frame</a></code> element.</p>
<p>The <a href=#task-source>task source</a> for the <a href=#concept-task title=concept-task>tasks</a> above is the
<a href=#dom-manipulation-task-source>DOM manipulation task source</a>.</p>
@@ -100929,27 +100981,27 @@
<th> Value
<tbody><tr><th id=ix-handler-onabort> <code title="">onabort</code>
<td> <a href=#handler-onabort title=handler-onabort>HTML elements</a>
- <td> <code title=event-abort>abort</code> event handler
+ <td> <code title=event-abort><a href=#event-abort>abort</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onafterprint> <code title="">onafterprint</code>
<td> <code title=handler-window-onafterprint><a href=#handler-window-onafterprint>body</a></code>
- <td> <code title=event-afterprint>afterprint</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-afterprint><a href=#event-afterprint>afterprint</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onbeforeprint> <code title="">onbeforeprint</code>
<td> <code title=handler-window-onbeforeprint><a href=#handler-window-onbeforeprint>body</a></code>
- <td> <code title=event-beforeprint>beforeprint</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-beforeprint><a href=#event-beforeprint>beforeprint</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onbeforeunload> <code title="">onbeforeunload</code>
<td> <code title=handler-window-onbeforeunload><a href=#handler-window-onbeforeunload>body</a></code>
- <td> <code title=event-beforeunload>beforeunload</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-beforeunload><a href=#event-beforeunload>beforeunload</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onblur> <code title="">onblur</code>
<td> <a href=#handler-onblur title=handler-onblur>HTML elements</a>
- <td> <code title=event-blur>blur</code> event handler
+ <td> <code title=event-blur><a href=#event-blur>blur</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oncancel> <code title="">oncancel</code>
@@ -100969,7 +101021,7 @@
<tr><th id=ix-handler-onchange> <code title="">onchange</code>
<td> <a href=#handler-onchange title=handler-onchange>HTML elements</a>
- <td> <code title=event-change>change</code> event handler
+ <td> <code title=event-change><a href=#event-change>change</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onclick> <code title="">onclick</code>
@@ -100984,57 +101036,57 @@
<tr><th id=ix-handler-oncontextmenu> <code title="">oncontextmenu</code>
<td> <a href=#handler-oncontextmenu title=handler-oncontextmenu>HTML elements</a>
- <td> <code title=event-contextmenu>contextmenu</code> event handler
+ <td> <code title=event-contextmenu><a href=#event-contextmenu>contextmenu</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oncuechange> <code title="">oncuechange</code>
<td> <a href=#handler-oncuechange title=handler-oncuechange>HTML elements</a>
- <td> <code title=event-cuechange>cuechange</code> event handler
+ <td> <code title=event-media-cuechange><a href=#event-media-cuechange>cuechange</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondblclick> <code title="">ondblclick</code>
<td> <a href=#handler-ondblclick title=handler-ondblclick>HTML elements</a>
- <td> <code title=event-dblclick>dblclick</code> event handler
+ <td> <code title=event-dblclick><a href=#event-dblclick>dblclick</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondrag> <code title="">ondrag</code>
<td> <a href=#handler-ondrag title=handler-ondrag>HTML elements</a>
- <td> <code title=event-drag><a href=#event-drag>drag</a></code> event handler
+ <td> <code title=event-dnd-drag><a href=#event-dnd-drag>drag</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragend> <code title="">ondragend</code>
<td> <a href=#handler-ondragend title=handler-ondragend>HTML elements</a>
- <td> <code title=event-dragend><a href=#event-dragend>dragend</a></code> event handler
+ <td> <code title=event-dnd-dragend><a href=#event-dnd-dragend>dragend</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragenter> <code title="">ondragenter</code>
<td> <a href=#handler-ondragenter title=handler-ondragenter>HTML elements</a>
- <td> <code title=event-dragenter><a href=#event-dragenter>dragenter</a></code> event handler
+ <td> <code title=event-dnd-dragenter><a href=#event-dnd-dragenter>dragenter</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragexit> <code title="">ondragexit</code>
<td> <a href=#handler-ondragexit title=handler-ondragexit>HTML elements</a>
- <td> <code title=event-dragexit><a href=#event-dragexit>dragexit</a></code> event handler
+ <td> <code title=event-dnd-dragexit><a href=#event-dnd-dragexit>dragexit</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragleave> <code title="">ondragleave</code>
<td> <a href=#handler-ondragleave title=handler-ondragleave>HTML elements</a>
- <td> <code title=event-dragleave><a href=#event-dragleave>dragleave</a></code> event handler
+ <td> <code title=event-dnd-dragleave><a href=#event-dnd-dragleave>dragleave</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragover> <code title="">ondragover</code>
<td> <a href=#handler-ondragover title=handler-ondragover>HTML elements</a>
- <td> <code title=event-dragover><a href=#event-dragover>dragover</a></code> event handler
+ <td> <code title=event-dnd-dragover><a href=#event-dnd-dragover>dragover</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondragstart> <code title="">ondragstart</code>
<td> <a href=#handler-ondragstart title=handler-ondragstart>HTML elements</a>
- <td> <code title=event-dragstart><a href=#event-dragstart>dragstart</a></code> event handler
+ <td> <code title=event-dnd-dragstart><a href=#event-dnd-dragstart>dragstart</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondrop> <code title="">ondrop</code>
<td> <a href=#handler-ondrop title=handler-ondrop>HTML elements</a>
- <td> <code title=event-drop><a href=#event-drop>drop</a></code> event handler
+ <td> <code title=event-dnd-drop><a href=#event-dnd-drop>drop</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-ondurationchange> <code title="">ondurationchange</code>
@@ -101054,12 +101106,12 @@
<tr><th id=ix-handler-onerror> <code title="">onerror</code>
<td> <a href=#handler-onerror title=handler-onerror>HTML elements</a>
- <td> <code title=event-error>error</code> event handler
+ <td> <code title=event-error><a href=#event-error>error</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onfocus> <code title="">onfocus</code>
<td> <a href=#handler-onfocus title=handler-onfocus>HTML elements</a>
- <td> <code title=event-focus>focus</code> event handler
+ <td> <code title=event-focus><a href=#event-focus>focus</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onhashchange> <code title="">onhashchange</code>
@@ -101069,32 +101121,32 @@
<tr><th id=ix-handler-oninput> <code title="">oninput</code>
<td> <a href=#handler-oninput title=handler-oninput>HTML elements</a>
- <td> <code title=event-input>input</code> event handler
+ <td> <code title=event-input><a href=#event-input>input</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-oninvalid> <code title="">oninvalid</code>
<td> <a href=#handler-oninvalid title=handler-oninvalid>HTML elements</a>
- <td> <code title=event-invalid>invalid</code> event handler
+ <td> <code title=event-invalid><a href=#event-invalid>invalid</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeydown> <code title="">onkeydown</code>
<td> <a href=#handler-onkeydown title=handler-onkeydown>HTML elements</a>
- <td> <code title=event-keydown>keydown</code> event handler
+ <td> <code title=event-keydown><a href=#event-keydown>keydown</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeypress> <code title="">onkeypress</code>
<td> <a href=#handler-onkeypress title=handler-onkeypress>HTML elements</a>
- <td> <code title=event-keypress>keypress</code> event handler
+ <td> <code title=event-keypress><a href=#event-keypress>keypress</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onkeyup> <code title="">onkeyup</code>
<td> <a href=#handler-onkeyup title=handler-onkeyup>HTML elements</a>
- <td> <code title=event-keyup>keyup</code> event handler
+ <td> <code title=event-keyup><a href=#event-keyup>keyup</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onload> <code title="">onload</code>
<td> <a href=#handler-onload title=handler-onload>HTML elements</a>
- <td> <code title=event-load>load</code> event handler
+ <td> <code title=event-load><a href=#event-load>load</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onloadeddata> <code title="">onloadeddata</code>
@@ -101119,42 +101171,42 @@
<tr><th id=ix-handler-onmousedown> <code title="">onmousedown</code>
<td> <a href=#handler-onmousedown title=handler-onmousedown>HTML elements</a>
- <td> <code title=event-mousedown>mousedown</code> event handler
+ <td> <code title=event-mousedown><a href=#event-mousedown>mousedown</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseenter> <code title="">onmouseenter</code>
<td> <a href=#handler-onmouseenter title=handler-onmouseenter>HTML elements</a>
- <td> <code title=event-mouseenter>mouseenter</code> event handler
+ <td> <code title=event-mouseenter><a href=#event-mouseenter>mouseenter</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseleave> <code title="">onmouseleave</code>
<td> <a href=#handler-onmouseleave title=handler-onmouseleave>HTML elements</a>
- <td> <code title=event-mouseleave>mouseleave</code> event handler
+ <td> <code title=event-mouseleave><a href=#event-mouseleave>mouseleave</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmousemove> <code title="">onmousemove</code>
<td> <a href=#handler-onmousemove title=handler-onmousemove>HTML elements</a>
- <td> <code title=event-mousemove>mousemove</code> event handler
+ <td> <code title=event-mousemove><a href=#event-mousemove>mousemove</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseout> <code title="">onmouseout</code>
<td> <a href=#handler-onmouseout title=handler-onmouseout>HTML elements</a>
- <td> <code title=event-mouseout>mouseout</code> event handler
+ <td> <code title=event-mouseout><a href=#event-mouseout>mouseout</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseover> <code title="">onmouseover</code>
<td> <a href=#handler-onmouseover title=handler-onmouseover>HTML elements</a>
- <td> <code title=event-mouseover>mouseover</code> event handler
+ <td> <code title=event-mouseover><a href=#event-mouseover>mouseover</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmouseup> <code title="">onmouseup</code>
<td> <a href=#handler-onmouseup title=handler-onmouseup>HTML elements</a>
- <td> <code title=event-mouseup>mouseup</code> event handler
+ <td> <code title=event-mouseup><a href=#event-mouseup>mouseup</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onmousewheel> <code title="">onmousewheel</code>
<td> <a href=#handler-onmousewheel title=handler-onmousewheel>HTML elements</a>
- <td> <code title=event-mousewheel>mousewheel</code> event handler
+ <td> <code title=event-mousewheel><a href=#event-mousewheel>mousewheel</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onoffline> <code title="">onoffline</code>
@@ -101209,17 +101261,17 @@
<tr><th id=ix-handler-onreset> <code title="">onreset</code>
<td> <a href=#handler-onreset title=handler-onreset>HTML elements</a>
- <td> <code title=event-reset>reset</code> event handler
+ <td> <code title=event-reset><a href=#event-reset>reset</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onresize> <code title="">onresize</code>
<td> <a href=#handler-onresize title=handler-onresize>HTML elements</a>
- <td> <code title=event-resize>resize</code> event handler
+ <td> <code title=event-resize><a href=#event-resize>resize</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onscroll> <code title="">onscroll</code>
<td> <a href=#handler-onscroll title=handler-onscroll>HTML elements</a>
- <td> <code title=event-scroll>scroll</code> event handler
+ <td> <code title=event-scroll><a href=#event-scroll>scroll</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onseeked> <code title="">onseeked</code>
@@ -101234,17 +101286,17 @@
<tr><th id=ix-handler-onselect> <code title="">onselect</code>
<td> <a href=#handler-onselect title=handler-onselect>HTML elements</a>
- <td> <code title=event-select>select</code> event handler
+ <td> <code title=event-select><a href=#event-select>select</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onshow> <code title="">onshow</code>
<td> <a href=#handler-onshow title=handler-onshow>HTML elements</a>
- <td> <code title=event-show>show</code> event handler
+ <td> <code title=event-show><a href=#event-show>show</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onsort> <code title="">onsort</code>
<td> <a href=#handler-onsort title=handler-onsort>HTML elements</a>
- <td> <code title=event-sort>sort</code> event handler
+ <td> <code title=event-sort><a href=#event-sort>sort</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onstalled> <code title="">onstalled</code>
@@ -101259,7 +101311,7 @@
<tr><th id=ix-handler-onsubmit> <code title="">onsubmit</code>
<td> <a href=#handler-onsubmit title=handler-onsubmit>HTML elements</a>
- <td> <code title=event-submit>submit</code> event handler
+ <td> <code title=event-submit><a href=#event-submit>submit</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onsuspend> <code title="">onsuspend</code>
@@ -101274,12 +101326,12 @@
<tr><th id=ix-handler-ontoggle> <code title="">ontoggle</code>
<td> <a href=#handler-ontoggle title=handler-ontoggle>HTML elements</a>
- <td> <code title=event-toggle>toggle</code> event handler
+ <td> <code title=event-toggle><a href=#event-toggle>toggle</a></code> event handler
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-window-onunload> <code title="">onunload</code>
<td> <code title=handler-window-onunload><a href=#handler-window-onunload>body</a></code>
- <td> <code title=event-unload>unload</code> event handler for <code><a href=#window>Window</a></code> object
+ <td> <code title=event-unload><a href=#event-unload>unload</a></code> event handler for <code><a href=#window>Window</a></code> object
<td> <a href=#event-handler-content-attributes title="event handler content attributes">Event handler content attribute</a>
<tr><th id=ix-handler-onvolumechange> <code title="">onvolumechange</code>
@@ -101834,8 +101886,217 @@
</ul>
+ <h3 class=no-num id=events-0>Events</h3>
+ <p><i>This section is non-normative.</i></p>
+ <table><caption>List of events</caption>
+ <thead><tr><th> Event
+ <th> Interface
+ <th> Interesting targets
+ <th> Description
+ <tbody><tr><!-- abort --><td> <dfn id=event-abort title=event-abort><code>abort</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the download was aborted by the user
+
+ <tr><!-- DOMContentLoaded --><td> <dfn id=event-domcontentloaded title=event-DOMContentLoaded><code>DOMContentLoaded</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#document>Document</a></code>
+ <td> Fired at the <code><a href=#document>Document</a></code> once the parser has finished
+
+ <tr><!-- afterprint --><td> <dfn id=event-afterprint title=event-afterprint><code>afterprint</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> after printing
+
+ <tr><!-- afterscriptexecute --><td> <dfn id=event-afterscriptexecute title=event-afterscriptexecute><code>afterscriptexecute</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-script-element>script</a></code> elements
+ <td> Fired at <code><a href=#the-script-element>script</a></code> elements after the script runs (just before the corresponding <code title=event-load><a href=#event-load>load</a></code> event)
+
+ <tr><!-- beforeprint --><td> <dfn id=event-beforeprint title=event-beforeprint><code>beforeprint</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> before printing
+
+ <tr><!-- beforescriptexecute --><td> <dfn id=event-beforescriptexecute title=event-beforescriptexecute><code>beforescriptexecute</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-script-element>script</a></code> elements
+ <td> Fired at <code><a href=#the-script-element>script</a></code> elements just before the script runs; canceling the event cancels the running of the script
+
+ <tr><!-- beforeunload --><td> <dfn id=event-beforeunload title=event-beforeunload><code>beforeunload</code></dfn>
+ <td> <code><a href=#beforeunloadevent>BeforeUnloadEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page is about to be unloaded, in case the page would like to show a warning prompt
+
+ <tr><!-- blur --><td> <dfn id=event-blur title=event-blur><code>blur</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at nodes losing focus <!-- XXX bug 23475 -->
+
+ <tr><!-- cancel --><td> <dfn id=event-cancel title=event-cancel><code>cancel</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-dialog-element>dialog</a></code> elements
+ <td> Fired at <code><a href=#the-dialog-element>dialog</a></code> elements when they are canceled by the user (e.g. by pressing the Escape key)
+
+ <tr><!-- change --><td> <dfn id=event-change title=event-change><code>change</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls when the user commits a value change (see also the <code title=event-input-change><a href=#event-input-change>change</a></code> event of <code><a href=#the-input-element>input</a></code> elements)
+
+ <tr><!-- click --><td> <code title=event-click><a href=#event-click>click</a></code>
+ <td> <code><a href=#mouseevent>MouseEvent</a></code>
+ <td> Elements
+ <td> Normally a mouse event; also synthetically fired at an element before its <a href=#activation-behavior>activation behavior</a> is run, when an element is activated from a non-pointer input device (e.g. a keyboard)
+
+ <tr><!-- close --><td> <dfn id=event-close title=event-close><code>close</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-dialog-element>dialog</a></code> elements, <code><a href=#websocket>WebSocket</a></code>
+ <td> Fired at <code><a href=#the-dialog-element>dialog</a></code> elments when they are closed, and at <code><a href=#websocket>WebSocket</a></code> elements when the connection is terminated
+
+ <tr><!-- connnect --><td> <dfn id=event-workerglobalscope-connect title=event-WorkerGlobalScope-connect><code>connnect</code></dfn>
+ <td> <code><a href=#messageevent>MessageEvent</a></code>
+ <td> <code><a href=#sharedworkerglobalscope>SharedWorkerGlobalScope</a></code>
+ <td> Fired at a shared worker's global scope when a new client connects
+
+ <tr><!-- contextmenu --><td> <dfn id=event-contextmenu title=event-contextmenu><code>contextmenu</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Elements
+ <td> Fired at elements when the user requests their context menu
+
+ <tr><!-- error --><td> <dfn id=event-error title=event-error><code>error</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects, <code><a href=#worker>Worker</a></code> objects, elements, networking-related objects
+ <td> Fired when unexpected errors occur (e.g. networking errors, script errors, decoding errors)
+
+ <tr><!-- focus --><td> <dfn id=event-focus title=event-focus><code>focus</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at nodes gaining focus <!-- XXX bug 23475 -->
+
+ <tr><!-- hashchange --><td> <dfn id=event-hashchange title=event-hashchange><code>hashchange</code></dfn>
+ <td> <code><a href=#hashchangeevent>HashChangeEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the fragment identifier part of <a href="#the-document's-address">the document's address</a> changes
+
+ <tr><!-- input --><td> <dfn id=event-input title=event-input><code>input</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls when the user changes the value (see also the <code title=event-input-change><a href=#event-input-change>change</a></code> event of <code><a href=#the-input-element>input</a></code> elements)
+
+ <tr><!-- invalid --><td> <dfn id=event-invalid title=event-invalid><code>invalid</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at controls during form validation if they do not satisfy their constraints
+
+ <tr><!-- load --><td> <dfn id=event-load title=event-load><code>load</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>, elements
+ <td> Fired at the <code><a href=#window>Window</a></code> when the document has finished loading; fired at an element containing a resource (e.g. <code><a href=#the-img-element>img</a></code>, <code><a href=#the-embed-element>embed</a></code>) when its resource has finished loading
+
+ <tr><!-- loadend --><td> <dfn id=event-loadend title=event-loadend><code>loadend</code></dfn>
+ <td> <code><a href=#event>Event</a></code> or <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements after a successful load (see also <span title=event-media-loadend>media element events</span>)
+
+ <tr><!-- loadstart --><td> <dfn id=event-loadstart title=event-loadstart><code>loadstart</code></dfn>
+ <td> <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements when a load begins (see also <a href=#event-media-loadstart title=event-media-loadstart>media element events</a>)
+
+ <tr><!-- message --><td> <dfn id=event-message title=event-message><code>message</code></dfn>
+ <td> <code><a href=#messageevent>MessageEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>, <code><a href=#eventsource>EventSource</a></code>, <code><a href=#websocket>WebSocket</a></code>, <code><a href=#messageport>MessagePort</a></code>, <code><a href=#broadcastchannel>BroadcastChannel</a></code>, <code><a href=#dedicatedworkerglobalscope>DedicatedWorkerGlobalScope</a></code>, <code><a href=#worker>Worker</a></code>
+ <td> Fired at an object when it receives a message
+
+ <tr><!-- offline --><td> <dfn id=event-offline title=event-offline><code>offline</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections fails
+
+ <tr><!-- online --><td> <dfn id=event-online title=event-online><code>online</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections returns
+
+ <tr><!-- open --><td> <dfn id=event-open title=event-open><code>open</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#eventsource>EventSource</a></code>, <code><a href=#websocket>WebSocket</a></code>
+ <td> Fired at networking-related objects when a connection is established
+
+ <tr><!-- pagehide --><td> <dfn id=event-pagehide title=event-pagehide><code>pagehide</code></dfn>
+ <td> <code><a href=#pagetransitionevent>PageTransitionEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page's entry in the <a href=#session-history>session history</a> stops being the <a href=#current-entry>current entry</a>
+
+ <tr><!-- pageshow --><td> <dfn id=event-pageshow title=event-pageshow><code>pageshow</code></dfn>
+ <td> <code><a href=#pagetransitionevent>PageTransitionEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the page's entry in the <a href=#session-history>session history</a> becomes the <a href=#current-entry>current entry</a>
+
+ <tr><!-- popstate --><td> <dfn id=event-popstate title=event-popstate><code>popstate</code></dfn>
+ <td> <code><a href=#popstateevent>PopStateEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> when the user navigates the <a href=#session-history>session history</a>
+
+ <tr><!-- progress --><td> <dfn id=event-progress title=event-progress><code>progress</code></dfn>
+ <td> <code><a href=#progressevent>ProgressEvent</a></code>
+ <td> <code><a href=#the-img-element>img</a></code> elements
+ <td> Fired at <code><a href=#the-img-element>img</a></code> elements during a <a href=#cors-same-origin>CORS-same-origin</a> image load (see also <a href=#event-media-progress title=event-media-progress>media element events</a>)
+
+ <tr><!-- readystatechange --><td> <dfn id=event-readystatechange title=event-readystatechange><code>readystatechange</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#document>Document</a></code>
+ <td> Fired at the <code><a href=#document>Document</a></code> when it finishes parsing and again when all its subresources have finished loading
+
+ <tr><!-- reset --><td> <dfn id=event-reset title=event-reset><code>reset</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-form-element>form</a></code> elements
+ <td> Fired at a <code><a href=#the-form-element>form</a></code> element when it is <a href=#concept-form-reset title=concept-form-reset>reset</a>
+
+ <tr><!-- select --><td> <dfn id=event-select title=event-select><code>select</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> Form controls
+ <td> Fired at form controls when an API adjusts the text selection
+
+ <tr><!-- show --><td> <dfn id=event-show title=event-show><code>show</code></dfn>
+ <td> <code><a href=#relatedevent>RelatedEvent</a></code>
+ <td> <code><a href=#the-menu-element>menu</a></code> elements
+ <td> Fired at a <code><a href=#the-menu-element>menu</a></code> element when it is shown as a context menu
+
+ <tr><!-- sort --><td> <dfn id=event-sort title=event-sort><code>sort</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-table-element>table</a></code> elements
+ <td> Fired at <code><a href=#the-table-element>table</a></code> elements before it is sorted; canceling the event cancels the sorting of the table
+
+ <tr><!-- storage --><td> <dfn id=event-storage title=event-storage><code>storage</code></dfn>
+ <td> <code><a href=#storageevent>StorageEvent</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at <code><a href=#window>Window</a></code> event when the corresponding <code title=dom-localStorage><a href=#dom-localstorage>localStorage</a></code> or <code title=dom-sessionStorage><a href=#dom-sessionstorage>sessionStorage</a></code> storage areas change
+
+ <tr><!-- submit --><td> <dfn id=event-submit title=event-submit><code>submit</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-form-element>form</a></code> elements
+ <td> Fired at a <code><a href=#the-form-element>form</a></code> element when it is <a href=#concept-form-submit title=concept-form-submit>submitted</a>
+
+ <tr><!-- toggle --><td> <dfn id=event-toggle title=event-toggle><code>toggle</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#the-details-element>details</a></code> element
+ <td> Fired at <code><a href=#the-details-element>details</a></code> elements when they open or close
+
+ <tr><!-- unload --><td> <dfn id=event-unload title=event-unload><code>unload</code></dfn>
+ <td> <code><a href=#event>Event</a></code>
+ <td> <code><a href=#window>Window</a></code>
+ <td> Fired at the <code><a href=#window>Window</a></code> object when the page is going away
+
+ </table><!--CLEANUP--><p class=note>See also <a href=#mediaevents>media element
+ events</a>, <a href=#appcacheevents>application cache events</a>,
+ and <a href=#dndevents>drag-and-drop events</a>.</p>
+
+
+
+
<h2 class=no-num id=references>References</h2><!--REFS-->
<p>All references are normative unless marked "Non-normative".</p>
Modified: source
===================================================================
--- source 2014-01-08 00:24:35 UTC (rev 8384)
+++ source 2014-01-08 23:55:07 UTC (rev 8385)
@@ -2542,9 +2542,23 @@
<li>The <dfn><code>UIEvent</code></dfn> interface's <dfn data-x="dom-UIEvent-detail"><code>detail</code></dfn> attribute</li>
<li><dfn data-x="event-click"><code>click</code></dfn> event</li>
+ <li><dfn data-x="event-dblclick"><code>dblclick</code></dfn> event</li>
+ <li><dfn data-x="event-mousedown"><code>mousedown</code></dfn> event</li>
+ <li><dfn data-x="event-mouseenter"><code>mouseenter</code></dfn> event</li>
+ <li><dfn data-x="event-mouseleave"><code>mouseleave</code></dfn> event</li>
+ <li><dfn data-x="event-mousemove"><code>mousemove</code></dfn> event</li>
+ <li><dfn data-x="event-mouseout"><code>mouseout</code></dfn> event</li>
+ <li><dfn data-x="event-mouseover"><code>mouseover</code></dfn> event</li>
+ <li><dfn data-x="event-mouseup"><code>mouseup</code></dfn> event</li>
+ <li><dfn data-x="event-mousewheel"><code>mousewheel</code></dfn> event</li>
+ <li><dfn data-x="event-keydown"><code>keydown</code></dfn> event</li>
+ <li><dfn data-x="event-keyup"><code>keyup</code></dfn> event</li>
+ <li><dfn data-x="event-keypress"><code>keypress</code></dfn> event</li>
+
</ul>
+<!--CLEANUP-->
<p>This specification sometimes uses the term <dfn
data-x="">name</dfn> to refer to the event's <code
data-x="dom-event-type">type</code>; as in, "an event named <code
@@ -2706,6 +2720,10 @@
<dfn><code>FontLoader</code></dfn>. <a href="#refsCSSFONTS">[CSSFONTS]</a> <a
href="#refsCSSFONTLOAD">[CSSFONTLOAD]</a></p>
+ <p>Some CSS specification will one day probably specify the <dfn
+ data-x="event-resize"><code>resize</code></dfn> and <dfn
+ data-x="event-scroll"><code>scroll</code></dfn> events.</p>
+
</dd>
@@ -8423,13 +8441,14 @@
<div class="impl">
+<!--CLEANUP-->
<p>Each document has a <dfn>current document readiness</dfn>. When a <code>Document</code> object
is created, it must have its <span>current document readiness</span> set to the string "<code
data-x="">loading</code>" if the document is associated with an <span>HTML parser</span>, an
<span>XML parser</span>, or an XSLT processor, and to the string "<code data-x="">complete</code>"
otherwise. Various algorithms during page loading affect this value. When the value is set, the
- user agent must <span>fire a simple event</span> named <dfn
- data-x="event-readystatechange"><code>readystatechange</code></dfn> at the <code>Document</code>
+ user agent must <span>fire a simple event</span> named <code
+ data-x="event-readystatechange">readystatechange</code> at the <code>Document</code>
object.</p>
<p>A <code>Document</code> is said to have an <dfn>active parser</dfn> if it is associated with an
@@ -28076,7 +28095,7 @@
following <a href="#resourceSuspend">the rules described previously</a>, which involve the
<code data-x="dom-media-networkState">networkState</code> attribute switching to the <code
data-x="dom-media-NETWORK_IDLE">NETWORK_IDLE</code> value and a <code
- data-x="event-suspend">suspend</code> event firing.</p>
+ data-x="event-media-suspend">suspend</code> event firing.</p>
<p class="note">The user agent is <em>required</em> to determine the duration of the
<span>media resource</span> and go through this step before playing.</p> <!-- actually defined
@@ -29562,18 +29581,18 @@
</li>
<li><p>For each <span data-x="text track cue">text track cue</span> in <var data-x="">missed
- cues</var>, <span>prepare an event</span> named <code data-x="event-enter">enter</code> for the
+ cues</var>, <span>prepare an event</span> named <code data-x="event-media-enter">enter</code> for the
<code>TextTrackCue</code> object with the <span>text track cue start time</span>.</p></li>
<li><p>For each <span data-x="text track cue">text track cue</span> in <var data-x="">other
cues</var> that either has its <span>text track cue active flag</span> set or is in <var
data-x="">missed cues</var>, <span>prepare an event</span> named <code
- data-x="event-exit">exit</code> for the <code>TextTrackCue</code> object with the later of the
+ data-x="event-media-exit">exit</code> for the <code>TextTrackCue</code> object with the later of the
<span>text track cue end time</span> and the <span>text track cue start time</span>.</p></li>
<li><p>For each <span data-x="text track cue">text track cue</span> in <var data-x="">current
cues</var> that does not have its <span>text track cue active flag</span> set, <span>prepare an
- event</span> named <code data-x="event-enter">enter</code> for the <code>TextTrackCue</code>
+ event</span> named <code data-x="event-media-enter">enter</code> for the <code>TextTrackCue</code>
object with the <span>text track cue start time</span>.</p></li>
<li>
@@ -29587,8 +29606,8 @@
<p>Finally, sort <span data-x="concept-task">tasks</span> in <var data-x="">events</var> that have
the same time and same <span>text track cue order</span> by placing <span
- data-x="concept-task">tasks</span> that fire <code data-x="event-enter">enter</code> events before
- those that fire <code data-x="event-exit">exit</code> events.</p>
+ data-x="concept-task">tasks</span> that fire <code data-x="event-media-enter">enter</code> events before
+ those that fire <code data-x="event-media-exit">exit</code> events.</p>
</li>
@@ -29601,9 +29620,9 @@
<li><p>For each <span>text track</span> in <var data-x="">affected tracks</var>, in the list
order, <span>queue a task</span> to <span>fire a simple event</span> named <code
- data-x="event-cuechange">cuechange</code> at the <code>TextTrack</code> object, and, if the
+ data-x="event-media-cuechange">cuechange</code> at the <code>TextTrack</code> object, and, if the
<span>text track</span> has a corresponding <code>track</code> element, to then <span>fire a
- simple event</span> named <code data-x="event-cuechange">cuechange</code> at the
+ simple event</span> named <code data-x="event-media-cuechange">cuechange</code> at the
<code>track</code> element as well.</p></li>
<li><p>Set the <span>text track cue active flag</span> of all the <span data-x="text track
@@ -32908,7 +32927,7 @@
<div class="impl">
- <h6 id="cue-events">Event definitions</h6>
+ <h6 id="cue-events">Event handlers for objects of the text track APIs</h6>
<p>The following are the <span>event handlers</span> that (and their corresponding <span
data-x="event handler event type">event handler event types</span>) must be supported, as <span>event handler IDL
@@ -32931,7 +32950,7 @@
<thead>
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
- <tr><td><dfn data-x="handler-TextTrack-oncuechange"><code>oncuechange</code></dfn> <td> <code data-x="event-cuechange">cuechange</code>
+ <tr><td><dfn data-x="handler-TextTrack-oncuechange"><code>oncuechange</code></dfn> <td> <code data-x="event-media-cuechange">cuechange</code>
</table>
<p>The following are the <span>event handlers</span> that (and their corresponding <span
@@ -32942,8 +32961,8 @@
<thead>
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
- <tr><td><dfn data-x="handler-TextTrackCue-onenter"><code>onenter</code></dfn> <td> <code data-x="event-enter">enter</code>
- <tr><td><dfn data-x="handler-TextTrackCue-onexit"><code>onexit</code></dfn> <td> <code data-x="event-exit">exit</code>
+ <tr><td><dfn data-x="handler-TextTrackCue-onenter"><code>onenter</code></dfn> <td> <code data-x="event-media-enter">enter</code>
+ <tr><td><dfn data-x="handler-TextTrackCue-onexit"><code>onexit</code></dfn> <td> <code data-x="event-media-exit">exit</code>
</table>
</div>
@@ -33283,7 +33302,7 @@
</div>
- <h5>Event definitions</h5>
+ <h5>The <code>TrackEvent</code> interface</h5>
<pre class="idl">[Constructor(DOMString type, optional <span>TrackEventInit</span> eventInitDict)]
interface <dfn>TrackEvent</dfn> : <span>Event</span> {
@@ -33710,15 +33729,6 @@
<tr>
- <td><dfn data-x="event-MediaController-ended"><code>ended</code></dfn>
-
- <td><code>Event</code>
-
- <td>The <code>MediaController</code> has reached the end of all the <span>slaved media
- elements</span>.
-
- <tr>
-
<td><dfn data-x="event-MediaController-waiting"><code>waiting</code></dfn>
<td><code>Event</code>
@@ -33727,11 +33737,12 @@
<tr>
- <td><dfn data-x="event-MediaContcoller-ended"><code>ended</code></dfn>
+ <td><dfn data-x="event-MediaController-ended"><code>ended</code></dfn>
<td><code>Event</code>
- <td>All the <span>slaved media elements</span> have newly <span>ended playback</span>.
+ <td>All the <span>slaved media elements</span> have newly <span>ended playback</span>; the
+ <code>MediaController</code> has reached the end of all the <span>slaved media elements</span>.
<tbody>
<tr>
@@ -33810,7 +33821,7 @@
<td><code>Event</code>
- <td>One or more tracks in the track list has been enabled or disabled.
+ <td>One or more tracks in the track list have been enabled or disabled.
<tr>
@@ -33831,6 +33842,65 @@
</table>
+
+ <p>The following event fires on <code>TextTrack</code> objects and <code>track</code> elements:</p>
+
+ <table>
+
+ <thead>
+ <tr>
+
+ <th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody>
+ <tr>
+
+ <td><dfn data-x="event-media-cuechange"><code>cuechange</code></dfn>
+
+ <td><code>Event</code>
+
+ <td>One or more cues in the track have become active or stopped being active.
+
+ </table>
+
+
+ <p>The following events fire on <code>TextTrackCue</code> objects:</p>
+
+ <table>
+
+ <thead>
+ <tr>
+
+ <th>Event name
+
+ <th>Interface
+
+ <th>Fired when...
+
+ <tbody>
+ <tr>
+
+ <td><dfn data-x="event-media-enter"><code>enter</code></dfn>
+
+ <td><code>Event</code>
+
+ <td>The cure has become active.
+
+ <tr>
+
+ <td><dfn data-x="event-media-exit"><code>exit</code></dfn>
+
+ <td><code>Event</code>
+
+ <td>The cure has stopped being active.
+
+ </table>
+
+
<!--ADD-TOPIC:Security-->
<div class="impl">
@@ -43486,7 +43556,7 @@
direction.</p></li>
<li><p><span>Queue a task</span> to <span>fire a simple event</span> that bubbles named <code
- data-x="event-input">input</code> at the <code>input</code> element.</p></li>
+ data-x="event-input-input">input</code> at the <code>input</code> element.</p></li>
</ol>
@@ -45710,8 +45780,8 @@
and the element's <code data-x="dom-input-indeterminate">indeterminate</code> IDL attribute back to
the values they had before the <span>pre-click activation steps</span> were run. The
<span>activation behavior</span> is to <span>fire a simple event</span> that bubbles named <code
- data-x="event-input">input</code> at the element and then <span>fire a simple event</span> that bubbles named <code
- data-x="event-change">change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ data-x="event-input-input">input</code> at the element and then <span>fire a simple event</span> that bubbles named <code
+ data-x="event-input-change">change</code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. --></p>
<p>If the element is not <i data-x="concept-fe-mutable">mutable</i>, it has no <span>activation
@@ -45869,8 +45939,8 @@
data-x="concept-fe-checked">checkedness</span> to true. The <span>canceled activation steps</span>
consist of setting the element's <span data-x="concept-fe-checked">checkedness</span> to false. The
<span>activation behavior</span> is to <span>fire a simple event</span> that bubbles named <code
- data-x="event-input">input</code> at the element and then <span>fire a simple event</span> that bubbles named <code
- data-x="event-change">change</code> at the element. <!-- It's not cancelable. Once this fires, the
+ data-x="event-input-input">input</code> at the element and then <span>fire a simple event</span> that bubbles named <code
+ data-x="event-input-change">change</code> at the element. <!-- It's not cancelable. Once this fires, the
control is checked, end of story. -->.</p>
<p>If the element is not <i data-x="concept-fe-mutable">mutable</i>, it has no <span>activation
@@ -45996,22 +46066,24 @@
<li><p>Wait for the user to have made their selection.</p></li>
+<!--CLEANUP-->
<li><p><span>Queue a task</span> to first update the element's <span
data-x="concept-input-type-file-selected">selected files</span> so that it represents the user's
selection, then <span>fire a simple event</span> that bubbles named <code
- data-x="event-input">input</code> at the <code>input</code> element, and finally <span>fire a
- simple event</span> that bubbles named <code data-x="event-change">change</code> at the
+ data-x="event-input-input">input</code> at the <code>input</code> element, and finally <span>fire a
+ simple event</span> that bubbles named <code data-x="event-input-change">change</code> at the
<code>input</code> element.</p></li>
</ol>
+<!--CLEANUP-->
<p>If the element is <i data-x="concept-fe-mutable">mutable</i>, the user agent should allow the
user to change the files on the list in other ways also, e.g. adding or removing files by
drag-and-drop. When the user does so, the user agent must <span>queue a task</span> to first
update the element's <span data-x="concept-input-type-file-selected">selected files</span> so that
it represents the user's new selection, then <span>fire a simple event</span> that bubbles named
- <code data-x="event-input">input</code> at the <code>input</code> element, and finally <span>fire
- a simple event</span> that bubbles named <code data-x="event-change">change</code> at the
+ <code data-x="event-input-input">input</code> at the <code>input</code> element, and finally <span>fire
+ a simple event</span> that bubbles named <code data-x="event-input-change">change</code> at the
<code>input</code> element.</p>
<p>If the element is not <i data-x="concept-fe-mutable">mutable</i>, it has no <span>activation
@@ -47897,7 +47969,7 @@
<h5 id="common-input-element-events">Common event behaviors</h5>
- <p>When the <code data-x="event-input">input</code> and <code data-x="event-change">change</code>
+ <p>When the <code data-x="event-input-input">input</code> and <code data-x="event-input-change">change</code>
events <span data-x="concept-input-apply">apply</span> (which is the case for all
<code>input</code> controls other than <span data-x="concept-button">buttons</span> and those with
the <code data-x="attr-input-type">type</code> attribute in the <span
@@ -47906,8 +47978,8 @@
event fires whenever the user has modified the data of the control. The <dfn
data-x="event-input-change"><code>change</code></dfn> event fires when the value is committed, if
that makes sense for the control, or else when the control loses focus. In all cases, the <code
- data-x="event-input">input</code> event comes before the corresponding <code
- data-x="event-change">change</code> event (if any).</p>
+ data-x="event-input-input">input</code> event comes before the corresponding <code
+ data-x="event-input-change">change</code> event (if any).</p>
<p>When an <code>input</code> element has a defined <span>activation behavior</span>, the rules
for dispatching these events, if they <span data-x="concept-input-apply">apply</span>, are given
@@ -47923,15 +47995,15 @@
interface involves both interactive manipulation and an explicit commit action, then when the user
changes the element's <span data-x="concept-fe-value">value</span>, the user agent must
<span>queue a task</span> to <span>fire a simple event</span> that bubbles named <code
- data-x="event-input">input</code> at the <code>input</code> element, and any time the user commits
+ data-x="event-input-input">input</code> at the <code>input</code> element, and any time the user commits
the change, the user agent must <span>queue a task</span> to <span>fire a simple event</span> that
- bubbles named <code data-x="event-change">change</code> at the <code>input</code> element.</p>
+ bubbles named <code data-x="event-input-change">change</code> at the <code>input</code> element.</p>
<p class="example">An example of a user interface involving both interactive manipulation and a
commit action would be a <span data-x="attr-input-type-range">Range</span> controls that use a
slider, when manipulated using a pointing device. While the user is dragging the control's knob,
- <code data-x="event-input">input</code> events would fire whenever the position changed, whereas
- the <code data-x="event-change">change</code> event would only fire when the user let go of the
+ <code data-x="event-input-input">input</code> events would fire whenever the position changed, whereas
+ the <code data-x="event-input-change">change</code> event would only fire when the user let go of the
knob, committing to a specific value.</p>
<p>For <code>input</code> elements without a defined <span>activation behavior</span>, but to
@@ -47939,8 +48011,8 @@
interface involves an explicit commit action but no intermediate manipulation, then any time the
user commits a change to the element's <span data-x="concept-fe-value">value</span>, the user
agent must <span>queue a task</span> to first <span>fire a simple event</span> that bubbles named
- <code data-x="event-input">input</code> at the <code>input</code> element, and then <span>fire a
- simple event</span> that bubbles named <code data-x="event-change">change</code> at the
+ <code data-x="event-input-input">input</code> at the <code>input</code> element, and then <span>fire a
+ simple event</span> that bubbles named <code data-x="event-input-change">change</code> at the
<code>input</code> element.</p>
<p class="example">An example of a user interface with a commit action would be a <span
@@ -47960,8 +48032,8 @@
which these events <span data-x="concept-input-apply">apply</span>, any time the user causes the
element's <span data-x="concept-fe-value">value</span> to change without an explicit commit
action, the user agent must <span>queue a task</span> to <span>fire a simple event</span> that
- bubbles named <code data-x="event-input">input</code> at the <code>input</code> element. The
- corresponding <code data-x="event-change">change</code> event, if any, will be fired when the
+ bubbles named <code data-x="event-input-input">input</code> at the <code>input</code> element. The
+ corresponding <code data-x="event-input-change">change</code> event, if any, will be fired when the
control <span data-x="unfocusing steps">loses focus</span>.</p>
<p class="example">Examples of a user changing the element's <span
@@ -47976,7 +48048,7 @@
step.</p>
<p>In the case of <span data-x="concept-task">tasks</span> that just fire an <code
- data-x="event-input">input</code> event, user agents may wait for a suitable break in the user's
+ data-x="event-input-input">input</code> event, user agents may wait for a suitable break in the user's
interaction before <span data-x="queue a task">queuing</span> the tasks; for example, a user agent
could wait for the user to have not hit a key for 100ms, so as to only fire the event when the
user pauses, instead of continuously for each keystroke. <!-- similar text is present in the
@@ -47986,8 +48058,8 @@
data-x="concept-fe-value">value</span> on behalf of the user (e.g. as part of a form prefilling
feature), the user agent must <span>queue a task</span> to first update the <span
data-x="concept-fe-value">value</span> accordingly, then <span>fire a simple event</span> that
- bubbles named <code data-x="event-input">input</code> at the <code>input</code> element, then
- <span>fire a simple event</span> that bubbles named <code data-x="event-change">change</code> at
+ bubbles named <code data-x="event-input-input">input</code> at the <code>input</code> element, then
+ <span>fire a simple event</span> that bubbles named <code data-x="event-input-change">change</code> at
the <code>input</code> element.</p>
<p class="note">These events are not fired in response to changes made to the values of form
@@ -56043,7 +56115,7 @@
</div>
- <h5>Event definitions</h5>
+ <h5>The <code>RelatedEvent</code> interfaces</h5>
<pre class="idl">[Constructor(DOMString type, optional <span>RelatedEventInit</span> eventInitDict)]
interface <dfn>RelatedEvent</dfn> : <span>Event</span> {
@@ -56993,8 +57065,8 @@
</li>
- <li><p><span>Queue a task</span> to <span>fire a simple event</span> named <dfn
- data-x="event-close"><code>close</code></dfn> at <var data-x="">subject</var>.</p></li>
+ <li><p><span>Queue a task</span> to <span>fire a simple event</span> named <code
+ data-x="event-close">close</code> at <var data-x="">subject</var>.</p></li>
</ol>
@@ -57006,10 +57078,11 @@
<hr>
+<!--CLEANUP-->
<p><strong>Canceling dialogs</strong>: When a <code>Document</code>'s <span>pending dialog
stack</span> is not empty, user agents may provide a user interface that, upon activation, <span
- data-x="queue a task">queues a task</span> to <span>fire a simple event</span> named <dfn
- data-x="event-cancel"><code>cancel</code></dfn> that is cancelable at the top <code>dialog</code>
+ data-x="queue a task">queues a task</span> to <span>fire a simple event</span> named <code
+ data-x="event-cancel">cancel</code> that is cancelable at the top <code>dialog</code>
element on the <code>Document</code>'s <span>pending dialog stack</span>. The default action of
this event must be to check if that element has an <code data-x="attr-dialog-open">open</code>
attribute, and if it does, <span>close the dialog</span> with no return value.</p>
@@ -76209,14 +76282,11 @@
<p>The <span>task source</span> for the tasks mentioned above is the <span>DOM manipulation task
source</span>.</p>
+ </div>
- <h5>Event definitions</h5>
- </div>
+ <h5>The <code>PopStateEvent</code> interface</h5>
- <p>The <dfn data-x="event-popstate"><code>popstate</code></dfn> event is fired in certain cases
- when navigating to a <span>session history entry</span>.</p>
-
<pre class="idl">[Constructor(DOMString type, optional <span>PopStateEventInit</span> eventInitDict)]
interface <dfn>PopStateEvent</dfn> : <span>Event</span> {
readonly attribute any <span data-x="dom-PopStateEvent-state">state</span>;
@@ -76249,11 +76319,8 @@
</div>
- <hr>
- <p>The <dfn data-x="event-hashchange"><code>hashchange</code></dfn> event is fired when navigating
- to a <span>session history entry</span> whose <span>URL</span> differs from that of the previous
- one only in the fragment identifier.</p>
+ <h5>The <code>HashChangeEvent</code> interface</h5>
<pre class="idl">[Constructor(DOMString type, optional <span>HashChangeEventInit</span> eventInitDict)]
interface <dfn>HashChangeEvent</dfn> : <span>Event</span> {
@@ -76303,15 +76370,8 @@
</div>
- <hr>
- <p>The <dfn data-x="event-pageshow"><code>pageshow</code></dfn> event is fired when <span
- data-x="traverse the history">traversing</span> <em>to</em> a <span>session history entry</span>.
- The <dfn data-x="event-pagehide"><code>pagehide</code></dfn> event is fired when traversing
- <em>from</em> a <span>session history entry</span>. The specification uses the <span>page
- showing</span> flag to ensure that scripts receive these events in a consistent manner (e.g. that
- they never receive two <code data-x="event-pagehide">pagehide</code> events in a row without an
- intervening <code data-x="event-pageshow">pageshow</code>, or vice versa).</p>
+ <h5>The <code>PageTransitionEvent</code> interface</h5>
<pre class="idl">[Constructor(DOMString type, optional <span>PageTransitionEventInit</span> eventInitDict)]
interface <dfn>PageTransitionEvent</dfn> : <span>Event</span> {
@@ -76367,9 +76427,13 @@
<div class="impl">
<p>A <code>Document</code> has a <dfn
- data-x="concept-document-salvageable"><i>salvageable</i></dfn> state, which must initially be true,
- a <dfn>fired unload</dfn> flag, which must initially be false, and a <dfn>page showing</dfn> flag,
- which must initially be false.</p>
+ data-x="concept-document-salvageable"><i>salvageable</i></dfn> state, which must initially be
+ true, a <dfn>fired unload</dfn> flag, which must initially be false, and a <dfn>page showing</dfn>
+ flag, which must initially be false. The <span>page showing</span> flag is used to ensure that
+ scripts receive <code data-x="event-pageshow">pageshow</code> and <code
+ data-x="event-pagehide">pagehide</code> events in a consistent manner (e.g. that they never
+ receive two <code data-x="event-pagehide">pagehide</code> events in a row without an intervening
+ <code data-x="event-pageshow">pageshow</code>, or vice versa).</p>
<p><span data-x="event loop">Event loops</span> have a <dfn>termination nesting level</dfn>
counter, which must initially be zero.</p>
@@ -76576,11 +76640,11 @@
</ol>
+ </div>
- <h5>Event definition</h5>
- </div>
+ <h5>The <code>BeforeUnloadEvent</code> interface</h5>
<pre class="idl">interface <dfn>BeforeUnloadEvent</dfn> : <span>Event</span> {
attribute DOMString <span data-x="dom-BeforeUnloadEvent-returnValue">returnValue</span>;
@@ -78908,18 +78972,20 @@
requests a remote page (or knows that such an attempt would fail), and must return true
otherwise.</p>
+<!--CLEANUP-->
<p>When the value that would be returned by the <code
data-x="dom-navigator-onLine">navigator.onLine</code> attribute of a <code>Window</code> or
<code>WorkerGlobalScope</code> changes from true to false, the user agent must <span>queue a
- task</span> to <span>fire a simple event</span> named <dfn
- data-x="event-offline"><code>offline</code></dfn> at the <code>Window</code> or
+ task</span> to <span>fire a simple event</span> named <code
+ data-x="event-offline">offline</code> at the <code>Window</code> or
<code>WorkerGlobalScope</code> object.</p>
+<!--CLEANUP-->
<p>On the other hand, when the value that would be returned by the <code
data-x="dom-navigator-onLine">navigator.onLine</code> attribute of a <code>Window</code> or
<code>WorkerGlobalScope</code> changes from false to true, the user agent must <span>queue a
- task</span> to <span>fire a simple event</span> named <dfn
- data-x="event-online"><code>online</code></dfn> at the <code>Window</code> or
+ task</span> to <span>fire a simple event</span> named <code
+ data-x="event-online">online</code> at the <code>Window</code> or
<code>WorkerGlobalScope</code> object.</p>
<p>The <span>task source</span> for these <span data-x="concept-task">tasks</span> is the
@@ -80564,16 +80630,16 @@
<tr><td><dfn data-x="handler-onclick"><code>onclick</code></dfn> <td> <code data-x="event-click">click</code> <!-- widely used -->
<tr><td><dfn data-x="handler-onclose"><code>onclose</code></dfn> <td> <code data-x="event-close">close</code> <!-- new for <dialog> -->
<tr><td><dfn data-x="handler-oncontextmenu"><code>oncontextmenu</code></dfn> <td> <code data-x="event-contextmenu">contextmenu</code> <!-- widely used -->
- <tr><td><dfn data-x="handler-oncuechange"><code>oncuechange</code></dfn> <td> <code data-x="event-cuechange">cuechange</code>
+ <tr><td><dfn data-x="handler-oncuechange"><code>oncuechange</code></dfn> <td> <code data-x="event-media-cuechange">cuechange</code>
<tr><td><dfn data-x="handler-ondblclick"><code>ondblclick</code></dfn> <td> <code data-x="event-dblclick">dblclick</code> <!-- widely used -->
- <tr><td><dfn data-x="handler-ondrag"><code>ondrag</code></dfn> <td> <code data-x="event-drag">drag</code>
- <tr><td><dfn data-x="handler-ondragend"><code>ondragend</code></dfn> <td> <code data-x="event-dragend">dragend</code>
- <tr><td><dfn data-x="handler-ondragenter"><code>ondragenter</code></dfn> <td> <code data-x="event-dragenter">dragenter</code>
- <tr><td><dfn data-x="handler-ondragexit"><code>ondragexit</code></dfn> <td> <code data-x="event-dragexit">dragexit</code>
- <tr><td><dfn data-x="handler-ondragleave"><code>ondragleave</code></dfn> <td> <code data-x="event-dragleave">dragleave</code>
- <tr><td><dfn data-x="handler-ondragover"><code>ondragover</code></dfn> <td> <code data-x="event-dragover">dragover</code>
- <tr><td><dfn data-x="handler-ondragstart"><code>ondragstart</code></dfn> <td> <code data-x="event-dragstart">dragstart</code> <!-- widely used -->
- <tr><td><dfn data-x="handler-ondrop"><code>ondrop</code></dfn> <td> <code data-x="event-drop">drop</code>
+ <tr><td><dfn data-x="handler-ondrag"><code>ondrag</code></dfn> <td> <code data-x="event-dnd-drag">drag</code>
+ <tr><td><dfn data-x="handler-ondragend"><code>ondragend</code></dfn> <td> <code data-x="event-dnd-dragend">dragend</code>
+ <tr><td><dfn data-x="handler-ondragenter"><code>ondragenter</code></dfn> <td> <code data-x="event-dnd-dragenter">dragenter</code>
+ <tr><td><dfn data-x="handler-ondragexit"><code>ondragexit</code></dfn> <td> <code data-x="event-dnd-dragexit">dragexit</code>
+ <tr><td><dfn data-x="handler-ondragleave"><code>ondragleave</code></dfn> <td> <code data-x="event-dnd-dragleave">dragleave</code>
+ <tr><td><dfn data-x="handler-ondragover"><code>ondragover</code></dfn> <td> <code data-x="event-dnd-dragover">dragover</code>
+ <tr><td><dfn data-x="handler-ondragstart"><code>ondragstart</code></dfn> <td> <code data-x="event-dnd-dragstart">dragstart</code> <!-- widely used -->
+ <tr><td><dfn data-x="handler-ondrop"><code>ondrop</code></dfn> <td> <code data-x="event-dnd-drop">drop</code>
<tr><td><dfn data-x="handler-ondurationchange"><code>ondurationchange</code></dfn> <td> <code data-x="event-media-durationchange">durationchange</code>
<tr><td><dfn data-x="handler-onemptied"><code>onemptied</code></dfn> <td> <code data-x="event-media-emptied">emptied</code>
<tr><td><dfn data-x="handler-onended"><code>onended</code></dfn> <td> <code data-x="event-media-ended">ended</code>
@@ -80613,9 +80679,9 @@
<tr><td><dfn data-x="handler-onwaiting"><code>onwaiting</code></dfn> <td> <code data-x="event-media-waiting">waiting</code>
<!-- not supported, use dnd: -->
-<!--<tr><td><dfn data-x="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code data-x="event-beforecopy">beforecopy</code>--> <!-- widely used -->
-<!--<tr><td><dfn data-x="handler-oncopy"><code>oncopy</code></dfn> <td> <code data-x="event-copy">copy</code>--> <!-- widely used -->
-<!--<tr><td><dfn data-x="handler-onpaste"><code>onpaste</code></dfn> <td> <code data-x="event-paste">paste</code>--> <!-- widely used -->
+<!--<tr><td><dfn data-x="handler-onbeforecopy"><code>onbeforecopy</code></dfn> <td> <code data-x="event-cp-beforecopy">beforecopy</code>--> <!-- widely used -->
+<!--<tr><td><dfn data-x="handler-oncopy"><code>oncopy</code></dfn> <td> <code data-x="event-cp-copy">copy</code>--> <!-- widely used -->
+<!--<tr><td><dfn data-x="handler-onpaste"><code>onpaste</code></dfn> <td> <code data-x="event-cp-paste">paste</code>--> <!-- widely used -->
<!-- not supported yet (v2?): -->
<!--<tr><td><dfn data-x="handler-onselectstart"><code>onselectstart</code></dfn> <td> <code data-x="event-selectstart">selectstart</code>--> <!-- widely used -->
</table>
@@ -85695,7 +85761,7 @@
<p>To make an element draggable is simple: give the element a <code
data-x="attr-draggable">draggable</code> attribute, and set an event listener for <code
- data-x="event-dragstart">dragstart</code> that stores the data being dragged.</p>
+ data-x="event-dnd-dragstart">dragstart</code> that stores the data being dragged.</p>
<p>The event handler typically needs to check that it's not a text selection that is being
dragged, and then needs to store data into the <code>DataTransfer</code> object and set the
@@ -85733,11 +85799,11 @@
"<code>move</code>" to indicate that the data will be moved).</p>
<p class="note">Instead of using the <code data-x="attr-dropzone">dropzone</code> attribute, a drop
- target can handle the <code data-x="event-dragenter">dragenter</code> event (to report whether or
- not the drop target is to accept the drop) and the <code data-x="event-dragover">dragover</code>
+ target can handle the <code data-x="event-dnd-dragenter">dragenter</code> event (to report whether or
+ not the drop target is to accept the drop) and the <code data-x="event-dnd-dragover">dragover</code>
event (to specify what feedback is to be shown to the user).</p>
- <p>The <code data-x="event-drop">drop</code> event allows the actual drop to be performed. This
+ <p>The <code data-x="event-dnd-drop">drop</code> event allows the actual drop to be performed. This
event needs to be canceled, so that the <code
data-x="dom-DataTransfer-DropEffect">dropEffect</code> attribute's value can be used by the source
(otherwise it's reset).</p>
@@ -85770,7 +85836,7 @@
<hr>
<p>To remove the original element (the one that was dragged) from the display, the <code
- data-x="event-dragend">dragend</code> event can be used.</p>
+ data-x="event-dnd-dragend">dragend</code> event can be used.</p>
<p>For our example here, that means updating the original markup to handle that event:</p>
@@ -85898,7 +85964,7 @@
<dt><dfn data-x="concept-dnd-rw">Read/write mode</dfn></dt>
<dd>
- <p>For the <code data-x="event-dragstart">dragstart</code> event. New data can be added to the
+ <p>For the <code data-x="event-dnd-dragstart">dragstart</code> event. New data can be added to the
<span>drag data store</span>.</p>
</dd>
@@ -85906,7 +85972,7 @@
<dt><dfn data-x="concept-dnd-ro">Read-only mode</dfn></dt>
<dd>
- <p>For the <code data-x="event-drop">drop</code> event. The list of items representing dragged
+ <p>For the <code data-x="event-dnd-drop">drop</code> event. The list of items representing dragged
data can be read, including the data. No new data can be added.</p>
</dd>
@@ -85986,7 +86052,7 @@
<p>Returns the kinds of operations that are to be allowed.</p>
- <p>Can be set (during the <code data-x="event-dragstart">dragstart</code> event), to change the
+ <p>Can be set (during the <code data-x="event-dnd-dragstart">dragstart</code> event), to change the
allowed operations.</p>
<p>The possible values are "<code data-x="">none</code>", "<code data-x="">copy</code>", "<code
@@ -86021,7 +86087,7 @@
<dd>
<p>Returns an array listing the formats that were set in the <code
- data-x="event-dragstart">dragstart</code> event. In addition, if any files are being dragged,
+ data-x="event-dnd-dragstart">dragstart</code> event. In addition, if any files are being dragged,
then one of the types will be the string "<code data-x="">Files</code>".</p>
</dd>
@@ -86084,7 +86150,7 @@
<p>The <dfn data-x="dom-DataTransfer-effectAllowed"><code>effectAllowed</code></dfn> attribute is
used in the drag-and-drop processing model to initialize the <code
data-x="dom-DataTransfer-dropEffect">dropEffect</code> attribute during the <code
- data-x="event-dragenter">dragenter</code> and <code data-x="event-dragover">dragover</code> events.
+ data-x="event-dnd-dragenter">dragenter</code> and <code data-x="event-dnd-dragover">dragover</code> events.
When the <code>DataTransfer</code> object is created, the <code
data-x="dom-DataTransfer-effectAllowed">effectAllowed</code> attribute is set to a string value. On
getting, it must return its current value. On setting, if <span>drag data store</span>'s <span
@@ -86780,11 +86846,11 @@
<li>
- <p>If <var data-x="">e</var> is <code data-x="event-dragstart">dragstart</code>, set the
+ <p>If <var data-x="">e</var> is <code data-x="event-dnd-dragstart">dragstart</code>, set the
<span>drag data store mode</span> to the <span data-x="concept-dnd-rw">read/write
mode</span>.</p>
- <p>If <var data-x="">e</var> is <code data-x="event-drop">drop</code>, set the <span>drag data
+ <p>If <var data-x="">e</var> is <code data-x="event-dnd-drop">drop</code>, set the <span>drag data
store mode</span> to the <span data-x="concept-dnd-ro">read-only mode</span>.</p>
</li>
@@ -86800,15 +86866,15 @@
<p id="dropEffect-initialization">Set the <code
data-x="dom-DataTransfer-dropEffect">dropEffect</code> attribute to "<code data-x="">none</code>"
- if <var data-x="">e</var> is <code data-x="event-dragstart">dragstart</code>, <code
- data-x="event-drag">drag</code>, <code data-x="event-dragexit">dragexit</code>, or <code
- data-x="event-dragleave">dragleave</code>; to the value corresponding to the <span>current drag
- operation</span> if <var data-x="">e</var> is <code data-x="event-drop">drop</code> or <code
- data-x="event-dragend">dragend</code>; and to a value based on the <code
+ if <var data-x="">e</var> is <code data-x="event-dnd-dragstart">dragstart</code>, <code
+ data-x="event-dnd-drag">drag</code>, <code data-x="event-dnd-dragexit">dragexit</code>, or <code
+ data-x="event-dnd-dragleave">dragleave</code>; to the value corresponding to the <span>current drag
+ operation</span> if <var data-x="">e</var> is <code data-x="event-dnd-drop">drop</code> or <code
+ data-x="event-dnd-dragend">dragend</code>; and to a value based on the <code
data-x="dom-DataTransfer-effectAllowed">effectAllowed</code> attribute's value and the
drag-and-drop source, as given by the following table, otherwise (i.e. if <var data-x="">e</var>
- is <code data-x="event-dragenter">dragenter</code> or <code
- data-x="event-dragover">dragover</code>):</p>
+ is <code data-x="event-dnd-dragenter">dragenter</code> or <code
+ data-x="event-dnd-dragover">dragover</code>):</p>
<table>
<thead>
@@ -86883,8 +86949,8 @@
<p>Create a <span data-x="concept-events-trusted">trusted</span> <code>DragEvent</code> object
and initialize it to have the given name <var data-x="">e</var>, to bubble, to be cancelable
- unless <var data-x="">e</var> is <code data-x="event-dragexit">dragexit</code>, <code
- data-x="event-dragleave">dragleave</code>, or <code data-x="event-dragend">dragend</code>, and to
+ unless <var data-x="">e</var> is <code data-x="event-dnd-dragexit">dragexit</code>, <code
+ data-x="event-dnd-dragleave">dragleave</code>, or <code data-x="event-dnd-dragend">dragend</code>, and to
have the <code data-x="dom-UIEvent-detail">detail</code> attribute initialized to zero, the mouse
and key attributes initialized according to the state of the input devices as they would be for
user interaction events, the <code data-x="">relatedTarget</code> attribute initialized to null,
@@ -86905,7 +86971,7 @@
<li><p>Set the <span>drag data store allowed effects state</span> to the current value of <var
data-x="">dataTransfer</var>'s <code data-x="dom-DataTransfer-effectAllowed">effectAllowed</code>
attribute. (It can only have changed value if <var data-x="">e</var> is <code
- data-x="event-dragstart">dragstart</code>.)</p></li>
+ data-x="event-dnd-dragstart">dragstart</code>.)</p></li>
<li><p>Set the <span>drag data store mode</span> back to the <span
data-x="concept-dnd-p">protected mode</span> if it was changed in the first step.</p></li>
@@ -87138,7 +87204,7 @@
<li>
- <p><span>Fire a DND event</span> named <code data-x="event-dragstart">dragstart</code> at the
+ <p><span>Fire a DND event</span> named <code data-x="event-dnd-dragstart">dragstart</code> at the
<span>source node</span>.</p>
<p>If the event is canceled, then the drag-and-drop operation should not occur; abort these
@@ -87215,7 +87281,7 @@
<li>
- <p><span>Fire a DND event</span> named <code data-x="event-drag">drag</code> at the
+ <p><span>Fire a DND event</span> named <code data-x="event-dnd-drag">drag</code> at the
<span>source node</span>. If this event is canceled, the user agent must set the <span>current
drag operation</span> to "<code data-x="">none</code>" (no drag operation).</p>
@@ -87223,7 +87289,7 @@
<li>
- <p>If the <code data-x="event-drag">drag</code> event was not canceled and the user has not ended
+ <p>If the <code data-x="event-dnd-drag">drag</code> event was not canceled and the user has not ended
the drag-and-drop operation, check the state of the drag-and-drop operation, as follows:</p>
<ol>
@@ -87233,7 +87299,7 @@
<p>If the user is indicating a different <span>immediate user selection</span> than during the
last iteration (or if this is the first iteration), and if this <span>immediate user
selection</span> is not the same as the <span>current target element</span>, then <span>fire a
- DND event</span> named <code data-x="event-dragexit">dragexit</code> at the <span>current
+ DND event</span> named <code data-x="event-dnd-dragexit">dragexit</code> at the <span>current
target element</span>, and then update the <span>current target element</span> as follows:</p>
<dl class="switch">
@@ -87252,7 +87318,7 @@
<dd>
- <p><span>Fire a DND event</span> named <code data-x="event-dragenter">dragenter</code> at the
+ <p><span>Fire a DND event</span> named <code data-x="event-dnd-dragenter">dragenter</code> at the
<span>immediate user selection</span>.</p>
<p>If the event is canceled, then set the <span>current target element</span> to the
@@ -87294,7 +87360,7 @@
leave the <span>current target element</span> unchanged.</p>
<p>Otherwise, <span>fire a DND event</span> named <code
- data-x="event-dragenter">dragenter</code> at <var data-x="">new target</var>. Then, set the
+ data-x="event-dnd-dragenter">dragenter</code> at <var data-x="">new target</var>. Then, set the
<span>current target element</span> to <var data-x="">new target</var>, regardless of
whether that event was canceled or not.</p>
@@ -87310,7 +87376,7 @@
<dd>
- <p><span>Fire a DND event</span> named <code data-x="event-dragenter">dragenter</code> at
+ <p><span>Fire a DND event</span> named <code data-x="event-dnd-dragenter">dragenter</code> at
<span>the body element</span>, if there is one, or at the <code>Document</code> object, if
not. Then, set the <span>current target element</span> to <span>the body element</span>,
regardless of whether that event was canceled or not.</p>
@@ -87329,7 +87395,7 @@
<p>If the previous step caused the <span>current target element</span> to change, and if the
previous target element was not null or a part of a non-DOM document, then <span>fire a DND
- event</span> named <code data-x="event-dragleave">dragleave</code> at the previous target
+ event</span> named <code data-x="event-dnd-dragleave">dragleave</code> at the previous target
element.</p>
</li>
@@ -87337,10 +87403,10 @@
<li>
<p>If the <span>current target element</span> is a DOM element, then <span>fire a DND
- event</span> named <code data-x="event-dragover">dragover</code> at this <span>current target
+ event</span> named <code data-x="event-dnd-dragover">dragover</code> at this <span>current target
element</span>.</p>
- <p>If the <code data-x="event-dragover">dragover</code> event is not canceled, run the
+ <p>If the <code data-x="event-dnd-dragover">dragover</code> event is not canceled, run the
appropriate step from the following list:</p>
<dl class="switch">
@@ -87382,7 +87448,7 @@
</dl>
- <p>Otherwise (if the <code data-x="event-dragover">dragover</code> event <em>is</em> canceled),
+ <p>Otherwise (if the <code data-x="event-dnd-dragover">dragover</code> event <em>is</em> canceled),
set the <span>current drag operation</span> based on the values of the <code
data-x="dom-DataTransfer-effectAllowed">effectAllowed</code> and <code
data-x="dom-DataTransfer-dropEffect">dropEffect</code> attributes of the <code>DragEvent</code>
@@ -87468,7 +87534,7 @@
<li>
<p>Otherwise, if the user ended the drag-and-drop operation (e.g. by releasing the mouse button
- in a mouse-driven drag-and-drop interface), or if the <code data-x="event-drag">drag</code> event
+ in a mouse-driven drag-and-drop interface), or if the <code data-x="event-dnd-drag">drag</code> event
was canceled, then this will be the last iteration. Run the following steps, then stop the
drag-and-drop operation:</p>
@@ -87486,7 +87552,7 @@
<li><p>Let <var data-x="">dropped</var> be false.</p></li>
<li><p>If the <span>current target element</span> is a DOM element, <span>fire a DND
- event</span> named <code data-x="event-dragleave">dragleave</code> at it; otherwise, if it is
+ event</span> named <code data-x="event-dnd-dragleave">dragleave</code> at it; otherwise, if it is
not null, use platform-specific conventions for drag cancellation.</p></li>
<li><p>Set the <span>current drag operation</span> to "<code data-x="">none</code>".</p></li>
@@ -87500,7 +87566,7 @@
<li><p>Let <var data-x="">dropped</var> be true.</p></li>
<li><p>If the <span>current target element</span> is a DOM element, <span>fire a DND
- event</span> named <code data-x="event-drop">drop</code> at it; otherwise, use
+ event</span> named <code data-x="event-dnd-drop">drop</code> at it; otherwise, use
platform-specific conventions for indicating a drop.</p></li>
<li>
@@ -87547,7 +87613,7 @@
<li>
- <p><span>Fire a DND event</span> named <code data-x="event-dragend">dragend</code> at the
+ <p><span>Fire a DND event</span> named <code data-x="event-dnd-dragend">dragend</code> at the
<span>source node</span>.</p>
</li>
@@ -87555,7 +87621,7 @@
<li>
<p>Run the appropriate steps from the following list as the default action of the <code
- data-x="event-dragend">dragend</code> event:</p>
+ data-x="event-dnd-dragend">dragend</code> event:</p>
<dl class="switch">
@@ -87645,7 +87711,7 @@
<tbody>
<tr>
- <td><dfn data-x="event-dragstart"><code>dragstart</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragstart"><code>dragstart</code></dfn></td>
<td><span>Source node</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -87656,7 +87722,7 @@
</tr>
<tr>
- <td><dfn data-x="event-drag"><code>drag</code></dfn></td>
+ <td><dfn data-x="event-dnd-drag"><code>drag</code></dfn></td>
<td><span>Source node</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -87667,7 +87733,7 @@
</tr>
<tr>
- <td><dfn data-x="event-dragenter"><code>dragenter</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragenter"><code>dragenter</code></dfn></td>
<td><span>Immediate user selection</span> or <span>the body element</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -87678,7 +87744,7 @@
</tr>
<tr>
- <td><dfn data-x="event-dragexit"><code>dragexit</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragexit"><code>dragexit</code></dfn></td>
<td><span data-x="current target element">Previous target element</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -87689,7 +87755,7 @@
</tr>
<tr>
- <td><dfn data-x="event-dragleave"><code>dragleave</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragleave"><code>dragleave</code></dfn></td>
<td><span data-x="current target element">Previous target element</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -87700,7 +87766,7 @@
</tr>
<tr>
- <td><dfn data-x="event-dragover"><code>dragover</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragover"><code>dragover</code></dfn></td>
<td><span>Current target element</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -87711,7 +87777,7 @@
</tr>
<tr>
- <td><dfn data-x="event-drop"><code>drop</code></dfn></td>
+ <td><dfn data-x="event-dnd-drop"><code>drop</code></dfn></td>
<td><span>Current target element</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>✓ Cancelable</td>
@@ -87722,7 +87788,7 @@
</tr>
<tr>
- <td><dfn data-x="event-dragend"><code>dragend</code></dfn></td>
+ <td><dfn data-x="event-dnd-dragend"><code>dragend</code></dfn></td>
<td><span>Source node</span></td>
<!-- <td>✓ Bubbles</td> -->
<td>—</td>
@@ -87738,8 +87804,8 @@
<p>Not shown in the above table: all these events bubble, and the <code
data-x="dom-DataTransfer-effectAllowed">effectAllowed</code> attribute always has the value it had
- after the <code data-x="event-dragstart">dragstart</code> event, defaulting to "<code
- data-x="">uninitialized</code>" in the <code data-x="event-dragstart">dragstart</code> event.</p>
+ after the <code data-x="event-dnd-dragstart">dragstart</code> event, defaulting to "<code
+ data-x="">uninitialized</code>" in the <code data-x="event-dnd-dragstart">dragstart</code> event.</p>
@@ -88077,8 +88143,8 @@
the user agent should then follow the relevant platform-specific conventions for copy operations
(e.g. updating the clipboard).</p>
- <p>The events involved in this process are the <code data-x="event-dragstart">dragstart</code>,
- <code data-x="event-drag">drag</code>, and <code data-x="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code data-x="event-dnd-dragstart">dragstart</code>,
+ <code data-x="event-dnd-drag">drag</code>, and <code data-x="event-dnd-dragend">dragend</code> events.</p>
<h5>Cut to clipboard</h5>
@@ -88087,8 +88153,8 @@
copy operation (see the previous section), followed, if the copy was completed successfully, by <a
href="#contenteditable-delete">a selection delete operation</a>.</p>
- <p>The events involved in this process are the <code data-x="event-dragstart">dragstart</code>,
- <code data-x="event-drag">drag</code>, and <code data-x="event-dragend">dragend</code> events.</p>
+ <p>The events involved in this process are the <code data-x="event-dnd-dragstart">dragstart</code>,
+ <code data-x="event-dnd-drag">drag</code>, and <code data-x="event-dnd-dragend">dragend</code> events.</p>
<h5>Paste from clipboard</h5>
@@ -88101,9 +88167,9 @@
selection</span>) the element with the keyboard focus, and then ended the drag-and-drop operation
without canceling it.</p>
- <p>The events involved in this process are the <code data-x="event-dragenter">dragenter</code>,
- <code data-x="event-dragover">dragover</code>, <code data-x="event-dragexit">dragexit</code>, <code
- data-x="event-dragleave">dragleave</code>, and <code data-x="event-drop">drop</code> events.</p>
+ <p>The events involved in this process are the <code data-x="event-dnd-dragenter">dragenter</code>,
+ <code data-x="event-dnd-dragover">dragover</code>, <code data-x="event-dnd-dragexit">dragexit</code>, <code
+ data-x="event-dnd-dragleave">dragleave</code>, and <code data-x="event-dnd-drop">drop</code> events.</p>
<h5>Paste from selection</h5>
@@ -88125,14 +88191,14 @@
<h4>Security risks in the drag-and-drop model</h4>
<p>User agents must not make the data added to the <code>DataTransfer</code> object during the
- <code data-x="event-dragstart">dragstart</code> event available to scripts until the <code
- data-x="event-drop">drop</code> event, because otherwise, if a user were to drag sensitive
+ <code data-x="event-dnd-dragstart">dragstart</code> event available to scripts until the <code
+ data-x="event-dnd-drop">drop</code> event, because otherwise, if a user were to drag sensitive
information from one document to a second document, crossing a hostile third document in the
process, the hostile document could intercept the data.</p>
<p>For the same reason, user agents must consider a drop to be successful only if the user
specifically ended the drag operation — if any scripts end the drag operation, it must be
- considered unsuccessful (canceled) and the <code data-x="event-drop">drop</code> event must not be
+ considered unsuccessful (canceled) and the <code data-x="event-dnd-drop">drop</code> event must not be
fired.</p>
<p>User agents should take care to not start drag-and-drop operations in response to script
@@ -88171,14 +88237,13 @@
<!--FIXUP postmsg -1-->
<!--START complete--><!--START dev-html-->
- <h3>Event definitions</h3>
+ <h3>The <code>MessageEvent</code> interfaces</h3>
<p>Messages in <span>server-sent events</span>, <span>Web sockets</span>, <span>cross-document
- messaging</span>, <span>channel messaging</span>, and <span>broadcast channels</span> use the <dfn
- data-x="event-message"><code>message</code></dfn> event. </p>
+ messaging</span>, <span>channel messaging</span>, and <span>broadcast channels</span> use the
+ <code>MessageEvent</code> interface for their <code data-x="event-message">message</code>
+ events:</p>
- <p>The following interface is defined for this event:</p>
-
<pre class="idl">[Constructor(DOMString type, optional <span>MessageEventInit</span> eventInitDict)]
interface <dfn>MessageEvent</dfn> : <span>Event</span> {
readonly attribute any <span data-x="dom-MessageEvent-data">data</span>;
@@ -88238,9 +88303,10 @@
<dd>
+<!--CLEANUP-->
<p>Returns the <code>WindowProxy</code> of the source window, for <span>cross-document
messaging</span>, and the <code>MessagePort</code> being attached, in the <code
- data-x="event-connect">connect</code> event fired at <code>SharedWorkerGlobalScope</code>
+ data-x="event-WorkerGlobalScope-connect">connect</code> event fired at <code>SharedWorkerGlobalScope</code>
objects.</p>
</dd>
@@ -88281,7 +88347,7 @@
value it was initialized to. When the object is created, this attribute must be initialized to
null. It represents, in <span>cross-document messaging</span>, the <code>WindowProxy</code> of the
<span>browsing context</span> of the <code>Window</code> object from which the message came; and
- in the <code data-x="event-connect">connect</code> events used by <span
+ in the <code data-x="event-WorkerGlobalScope-connect">connect</code> events used by <span
data-x="SharedWorkerGlobalScope">shared workers</span>, the newly connecting
<code>MessagePort</code>.</p>
@@ -89386,7 +89452,7 @@
<p class="note">If the <i>establish a WebSocket connection</i> algorithm fails, it triggers the
<i>fail the WebSocket connection</i> algorithm, which then invokes the <i>close the WebSocket
connection</i> algorithm, which then establishes that <i>the WebSocket connection is closed</i>,
- which fires the <code data-x="event-socket-close">close</code> event <a href="#closeWebSocket">as
+ which fires the <code data-x="event-close">close</code> event <a href="#closeWebSocket">as
described below</a>.</p>
</li>
@@ -89488,7 +89554,7 @@
<p>Do nothing.</p>
<p class="note">The connection is already closing or is already closed. If it has not already,
- a <code data-x="event-socket-close">close</code> event will eventually fire <a
+ a <code data-x="event-close">close</code> event will eventually fire <a
href="#closeWebSocket">as described below</a>.</p>
</dd>
@@ -89505,7 +89571,7 @@
<p class="note">The <i>fail the WebSocket connection</i> algorithm invokes the <i>close the
WebSocket connection</i> algorithm, which then establishes that <i>the WebSocket connection is
- closed</i>, which fires the <code data-x="event-socket-close">close</code> event <a
+ closed</i>, which fires the <code data-x="event-close">close</code> event <a
href="#closeWebSocket">as described below</a>.</p>
</dd>
@@ -89531,7 +89597,7 @@
<p class="note">The <i>start the WebSocket closing handshake</i> algorithm eventually invokes
the <i>close the WebSocket connection</i> algorithm, which then establishes that <i>the
WebSocket connection is closed</i>, which fires the <code
- data-x="event-socket-close">close</code> event <a href="#closeWebSocket">as described
+ data-x="event-close">close</code> event <a href="#closeWebSocket">as described
below</a>.</p>
</dd>
@@ -89546,7 +89612,7 @@
<p class="note"><i>The WebSocket closing handshake is started</i>, and will eventually invoke
the <i>close the WebSocket connection</i> algorithm, which will establish that <i>the
- WebSocket connection is closed</i>, and thus the <code data-x="event-socket-close">close</code>
+ WebSocket connection is closed</i>, and thus the <code data-x="event-close">close</code>
event will fire, <a href="#closeWebSocket">as described below</a>.</p>
</dd>
@@ -89725,7 +89791,7 @@
<tr><td><dfn data-x="handler-WebSocket-onopen"><code>onopen</code></dfn> <td> <code data-x="event-open">open</code>
<tr><td><dfn data-x="handler-WebSocket-onmessage"><code>onmessage</code></dfn> <td> <code data-x="event-message">message</code>
<tr><td><dfn data-x="handler-WebSocket-onerror"><code>onerror</code></dfn> <td> <code data-x="event-error">error</code>
- <tr><td><dfn data-x="handler-WebSocket-onclose"><code>onclose</code></dfn> <td> <code data-x="event-socket-close">close</code>
+ <tr><td><dfn data-x="handler-WebSocket-onclose"><code>onclose</code></dfn> <td> <code data-x="event-close">close</code>
</table>
@@ -89884,7 +89950,7 @@
<li><p>Create a <span data-x="concept-events-trusted">trusted</span> event that uses the
<code>CloseEvent</code> interface, with the event type <code
- data-x="event-socket-close">close</code>, which does not bubble, is not cancelable, has no default
+ data-x="event-close">close</code>, which does not bubble, is not cancelable, has no default
action, whose <code data-x="dom-CloseEvent-wasClean">wasClean</code> attribute is initialized to
true if the connection closed <i data-x="">cleanly</i> and false otherwise, whose <code
data-x="dom-CloseEvent-code">code</code> attribute is initialized to <i>the WebSocket connection
@@ -90022,7 +90088,7 @@
</ol>
- <h4>Event definitions</h4>
+ <h4>The <code>CloseEvent</code> interfaces</h4>
<pre class="idl">[Constructor(DOMString type, optional <span>CloseEventInit</span> eventInitDict)]
interface <dfn>CloseEvent</dfn> : <span>Event</span> {
@@ -90059,20 +90125,20 @@
data-x="concept-task">task</span> must not be garbage collected if there are any event listeners
registered for <code data-x="event-open">open</code> events, <code
data-x="event-message">message</code> events, <code data-x="event-error">error</code> events, or
- <code data-x="event-socket-close">close</code> events.</p>
+ <code data-x="event-close">close</code> events.</p>
<p>A <code>WebSocket</code> object whose <code data-x="dom-WebSocket-readyState">readyState</code>
attribute's value was set to <code data-x="dom-WebSocket-OPEN">OPEN</code> (1) as of the last time
the <span>event loop</span> started executing a <span data-x="concept-task">task</span> must not be
garbage collected if there are any event listeners registered for <code
data-x="event-message">message</code> events, <code data-x="event-error">error</code>, or <code
- data-x="event-socket-close">close</code> events.</p>
+ data-x="event-close">close</code> events.</p>
<p>A <code>WebSocket</code> object whose <code data-x="dom-WebSocket-readyState">readyState</code>
attribute's value was set to <code data-x="dom-WebSocket-CLOSING">CLOSING</code> (2) as of the last
time the <span>event loop</span> started executing a <span data-x="concept-task">task</span> must
not be garbage collected if there are any event listeners registered for <code
- data-x="event-error">error</code> or <code data-x="event-socket-close">close</code> events.</p>
+ data-x="event-error">error</code> or <code data-x="event-close">close</code> events.</p>
<p>A <code>WebSocket</code> object with <i data-x="the WebSocket connection is established">an
established connection</i> that has data queued to be transmitted to the network must not be
@@ -91971,8 +92037,9 @@
worker.port.postMessage('some message');
worker.port.postMessage({ foo: 'structured', bar: ['data', 'also', 'possible']});</pre>
+<!--CLEANUP-->
<p>Inside the shared worker, new clients of the worker are announced using the <code
- data-x="event-connect">connect</code> event. The port for the new client is given by the event
+ data-x="event-WorkerGlobalScope-connect">connect</code> event. The port for the new client is given by the event
object's <code data-x="dom-messageevent-source">source</code> attribute.</p>
<pre>onconnect = function (event) {
@@ -92040,7 +92107,7 @@
<!-- v2-onclose (remember to specify the task source, too)
<li><p><span>Queue a task</span> to <span>fire a simple event</span> named <code
- data-x="event-worker-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
+ data-x="event-close">close</code> at the <code>WorkerGlobalScope</code> object.</p></li>
-->
<li><p>Set the worker's <code>WorkerGlobalScope</code> object's <span
@@ -92059,7 +92126,7 @@
<thead>
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
-<!-- v2-onclose <tr><td><dfn data-x="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code data-x="event-worker-close">close</code> -->
+<!-- v2-onclose <tr><td><dfn data-x="handler-WorkerGlobalScope-onclose"><code>onclose</code></dfn> <td> <code data-x="event-close">close</code> -->
<tr><td><dfn data-x="handler-WorkerGlobalScope-onerror"><code>onerror</code></dfn> <td> <code data-x="event-error">error</code>
<tr><td><dfn data-x="handler-WorkerGlobalScope-onoffline"><code>onoffline</code></dfn> <td> <code data-x="event-offline">offline</code> <!-- new -->
<tr><td><dfn data-x="handler-WorkerGlobalScope-ononline"><code>ononline</code></dfn> <td> <code data-x="event-online">online</code> <!-- new -->
@@ -92157,7 +92224,7 @@
<thead>
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
- <tr><td><dfn data-x="handler-SharedWorkerGlobalScope-onconnect"><code>onconnect</code></dfn> <td> <code data-x="event-connect">connect</code>
+ <tr><td><dfn data-x="handler-SharedWorkerGlobalScope-onconnect"><code>onconnect</code></dfn> <td> <code data-x="event-WorkerGlobalScope-connect">connect</code>
</table>
<p>For the purposes of the <span>application cache</span> networking model, a shared worker is its
@@ -92349,7 +92416,7 @@
no later than it stops being a <span>permissible worker</span>, <var data-x="">worker global
scope</var>'s <span data-x="dom-WorkerGlobalScope-closing">closing</span> flag is set to true<!--
v2-onclose and <span data-x="queue a task">a task is queued</span> to <span>fire a simple
- event</span> named <code data-x="event-worker-close">close</code> at <var data-x="">worker global
+ event</span> named <code data-x="event-close">close</code> at <var data-x="">worker global
scope</var>-->.</p>
</li>
@@ -92419,7 +92486,7 @@
<p>For each <code>Worker</code> or <code>SharedWorker</code> object associated with <var
data-x="">worker global scope</var>, <span>queue a task</span> to <span>fire a simple
- event</span> named <code data-x="event-worker-close">close</code> at that object.</p>
+ event</span> named <code data-x="event-close">close</code> at that object.</p>
</li>
-->
@@ -92444,7 +92511,7 @@
<!-- v2-onclose
<li><p>If the worker's <code>WorkerGlobalScope</code> object's <span
data-x="dom-WorkerGlobalScope-closing">closing</span> flag is false, <span>queue a task</span> to
- <span>fire a simple event</span> named <code data-x="event-worker-close">close</code> at the
+ <span>fire a simple event</span> named <code data-x="event-close">close</code> at the
worker's <code>WorkerGlobalScope</code> object.</p></li>
-->
@@ -92454,25 +92521,25 @@
<!-- v2-onclose
<li><p>Wait a user-agent-defined amount of time. If the "<span>run a worker</span>" processing
model defined above immediately starts running event listeners registered for the <code
- data-x="event-worker-close">close</code> event, this time should not be zero — the idea is
- that the <code data-x="event-worker-close">close</code> event can be used to clean up when
+ data-x="event-close">close</code> event, this time should not be zero — the idea is
+ that the <code data-x="event-close">close</code> event can be used to clean up when
shutting down unexpectedly.</p></li>
-->
<li><p>If there are any <span data-x="concept-task">tasks</span> queued in the
<code>WorkerGlobalScope</code> object's <span>event loop</span>'s <span data-x="task queue">task
- queues</span><!-- v2-onclose other than the <code data-x="event-worker-close">close</code> event
+ queues</span><!-- v2-onclose other than the <code data-x="event-close">close</code> event
that this algorithm just added-->, discard them without processing them.</p></li>
<!-- v2-onclose
- <li><p>If the <code data-x="event-worker-close">close</code> event that this algorithm just queued
+ <li><p>If the <code data-x="event-close">close</code> event that this algorithm just queued
hasn't yet been dispatched, then abort the script currently running in the worker.</p></li>
-->
<li><p>Wait a user-agent-defined amount of time.</p></li>
<li><p>Abort the script currently running in the worker<!-- v2-onclose (if any script is running,
- then it will be a handler for the <code data-x="event-worker-close">close</code>
+ then it will be a handler for the <code data-x="event-close">close</code>
event)-->.</p></li>
</ol>
@@ -92579,7 +92646,7 @@
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
<tr><td><dfn data-x="handler-AbstractWorker-onerror"><code>onerror</code></dfn> <td> <code data-x="event-error">error</code>
-<!-- v2-onclose <tr><td><dfn data-x="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code data-x="event-worker-close">close</code> -->
+<!-- v2-onclose <tr><td><dfn data-x="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code data-x="event-close">close</code> -->
</table>
@@ -93001,9 +93068,10 @@
<li><p><span>Entangle</span> <var data-x="">outside port</var>
and <var data-x="">inside port</var>.</p></li>
+<!--CLEANUP-->
<li><p>Create a <span data-x="concept-events-trusted">trusted</span> event that uses the
<code>MessageEvent</code> interface, with the name <code
- data-x="event-connect">connect</code>, which does not bubble, is not cancelable, has no
+ data-x="event-WorkerGlobalScope-connect">connect</code>, which does not bubble, is not cancelable, has no
default action, has a <code data-x="dom-MessageEvent-data">data</code> attribute whose value
is initialized to the empty string, has a <code data-x="dom-MessageEvent-ports">ports</code>
attribute whose value is initialized to a <span data-x="dfn-read-only-array">read only</span>
@@ -93067,8 +93135,9 @@
<li><p>Return <var data-x="">worker</var> and perform the remaining steps asynchronously.</p></li>
+<!--CLEANUP-->
<li><p>Create a <span data-x="concept-events-trusted">trusted</span> event that uses the
- <code>MessageEvent</code> interface, with the name <code data-x="event-connect">connect</code>,
+ <code>MessageEvent</code> interface, with the name <code data-x="event-WorkerGlobalScope-connect">connect</code>,
which does not bubble, is not cancelable, has no default action, has a <code
data-x="dom-MessageEvent-data">data</code> attribute whose value is initialized to the empty
string, has a <code data-x="dom-MessageEvent-ports">ports</code> attribute whose value is
@@ -93626,7 +93695,8 @@
<h5>The <code data-x="event-storage">storage</code> event</h5>
- <p>The <dfn data-x="event-storage"><code>storage</code></dfn> event is fired on a
+<!--CLEANUP-->
+ <p>The <code data-x="event-storage">storage</code> event is fired on a
<code>Document</code>'s <code>Window</code> object when a storage area changes, as described in
the previous two sections (<a href="#sessionStorageEvent">for session storage</a>, <a
href="#localStorageEvent">for local storage</a>).</p>
@@ -93667,7 +93737,7 @@
(i.e. session or local).</p>
- <h6>Event definition</h6>
+ <h6>The <code>StorageEvent</code> interface</h6>
<pre class="idl">[Constructor(DOMString type, optional <span>StorageEventInit</span> eventInitDict)]
interface <dfn>StorageEvent</dfn> : <span>Event</span> {
@@ -107831,7 +107901,7 @@
<code>marquee</code> element must be <span data-x="concept-marquee-off">turned off</span>.</p>
<p>When a <code>marquee</code> element is created, the user agent must <span>queue a task</span>
- to <span>fire a simple event</span> named <code data-x="event-start">start</code> at the
+ to <span>fire a simple event</span> named <code data-x="event-marquee-start">start</code> at the
element.</p>
<hr>
@@ -107953,15 +108023,15 @@
<p>If the <span>marquee current loop index</span> is now equal to or greater than the element's
<span>marquee loop count</span>, <span data-x="concept-marquee-off">turn off</span> the
<code>marquee</code> element and <span>queue a task</span> to <span>fire a simple event</span>
- named <code data-x="event-finish">finish</code> at the <code>marquee</code> element.</p>
+ named <code data-x="event-marquee-finish">finish</code> at the <code>marquee</code> element.</p>
<p>Otherwise, if the <code data-x="attr-marquee-behavior">behavior</code> attribute is in the
<span data-x="attr-marquee-behavior-alternate">alternate</span> state, then <span>queue a
- task</span> to <span>fire a simple event</span> named <code data-x="event-bounce">bounce</code>
+ task</span> to <span>fire a simple event</span> named <code data-x="event-marquee-bounce">bounce</code>
at the <code>marquee</code> element.</p>
<p>Otherwise, <span>queue a task</span> to <span>fire a simple event</span> named <code
- data-x="event-start">start</code> at the <code>marquee</code> element.</p>
+ data-x="event-marquee-start">start</code> at the <code>marquee</code> element.</p>
</li>
@@ -107977,9 +108047,9 @@
<thead>
<tr><th><span data-x="event handlers">Event handler</span> <th><span>Event handler event type</span>
<tbody>
- <tr><td><dfn data-x="handler-marquee-onbounce"><code>onbounce</code></dfn> <td> <code data-x="event-bounce">bounce</code>
- <tr><td><dfn data-x="handler-marquee-onfinish"><code>onfinish</code></dfn> <td> <code data-x="event-finish">finish</code>
- <tr><td><dfn data-x="handler-marquee-onstart"><code>onstart</code></dfn> <td> <code data-x="event-start">start</code>
+ <tr><td><dfn data-x="handler-marquee-onbounce"><code>onbounce</code></dfn> <td> <code data-x="event-marquee-bounce">bounce</code>
+ <tr><td><dfn data-x="handler-marquee-onfinish"><code>onfinish</code></dfn> <td> <code data-x="event-marquee-finish">finish</code>
+ <tr><td><dfn data-x="handler-marquee-onstart"><code>onstart</code></dfn> <td> <code data-x="event-marquee-start">start</code>
</table>
<hr>
@@ -112747,7 +112817,7 @@
<tr>
<th id="ix-handler-oncuechange"> <code data-x="">oncuechange</code>
<td> <span data-x="handler-oncuechange">HTML elements</span>
- <td> <code data-x="event-cuechange">cuechange</code> event handler
+ <td> <code data-x="event-media-cuechange">cuechange</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
@@ -112759,49 +112829,49 @@
<tr>
<th id="ix-handler-ondrag"> <code data-x="">ondrag</code>
<td> <span data-x="handler-ondrag">HTML elements</span>
- <td> <code data-x="event-drag">drag</code> event handler
+ <td> <code data-x="event-dnd-drag">drag</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragend"> <code data-x="">ondragend</code>
<td> <span data-x="handler-ondragend">HTML elements</span>
- <td> <code data-x="event-dragend">dragend</code> event handler
+ <td> <code data-x="event-dnd-dragend">dragend</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragenter"> <code data-x="">ondragenter</code>
<td> <span data-x="handler-ondragenter">HTML elements</span>
- <td> <code data-x="event-dragenter">dragenter</code> event handler
+ <td> <code data-x="event-dnd-dragenter">dragenter</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragexit"> <code data-x="">ondragexit</code>
<td> <span data-x="handler-ondragexit">HTML elements</span>
- <td> <code data-x="event-dragexit">dragexit</code> event handler
+ <td> <code data-x="event-dnd-dragexit">dragexit</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragleave"> <code data-x="">ondragleave</code>
<td> <span data-x="handler-ondragleave">HTML elements</span>
- <td> <code data-x="event-dragleave">dragleave</code> event handler
+ <td> <code data-x="event-dnd-dragleave">dragleave</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragover"> <code data-x="">ondragover</code>
<td> <span data-x="handler-ondragover">HTML elements</span>
- <td> <code data-x="event-dragover">dragover</code> event handler
+ <td> <code data-x="event-dnd-dragover">dragover</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondragstart"> <code data-x="">ondragstart</code>
<td> <span data-x="handler-ondragstart">HTML elements</span>
- <td> <code data-x="event-dragstart">dragstart</code> event handler
+ <td> <code data-x="event-dnd-dragstart">dragstart</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
<th id="ix-handler-ondrop"> <code data-x="">ondrop</code>
<td> <span data-x="handler-ondrop">HTML elements</span>
- <td> <code data-x="event-drop">drop</code> event handler
+ <td> <code data-x="event-dnd-drop">drop</code> event handler
<td> <span data-x="event handler content attributes">Event handler content attribute</span>
<tr>
@@ -113612,8 +113682,6 @@
<!--INTERFACES-->
-<!--END complete--><!-- (only has events from HTML5) -->
-
<h3 class="no-num">Events</h3>
<!--END dev-html--><p><i>This section is non-normative.</i></p><!--START dev-html-->
@@ -113624,149 +113692,252 @@
<tr>
<th> Event
<th> Interface
+ <th> Interesting targets
<th> Description
<tbody>
- <tr>
- <td> <code data-x="event-abort">abort</code>
+ <tr> <!-- abort -->
+ <td> <dfn data-x="event-abort"><code>abort</code></dfn>
<td> <code>Event</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the download was aborted by the user
- <tr>
- <td> <code data-x="event-afterprint">afterprint</code>
+ <tr> <!-- DOMContentLoaded -->
+ <td> <dfn data-x="event-DOMContentLoaded"><code>DOMContentLoaded</code></dfn>
<td> <code>Event</code>
+ <td> <code>Document</code>
+ <td> Fired at the <code>Document</code> once the parser has finished
+
+ <tr> <!-- afterprint -->
+ <td> <dfn data-x="event-afterprint"><code>afterprint</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> after printing
- <tr>
- <td> <code data-x="event-beforeprint">beforeprint</code>
+ <tr> <!-- afterscriptexecute -->
+ <td> <dfn data-x="event-afterscriptexecute"><code>afterscriptexecute</code></dfn>
<td> <code>Event</code>
+ <td> <code>script</code> elements
+ <td> Fired at <code>script</code> elements after the script runs (just before the corresponding <code data-x="event-load">load</code> event)
+
+ <tr> <!-- beforeprint -->
+ <td> <dfn data-x="event-beforeprint"><code>beforeprint</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> before printing
- <tr>
- <td> <code data-x="event-beforeunload">beforeunload</code>
+ <tr> <!-- beforescriptexecute -->
+ <td> <dfn data-x="event-beforescriptexecute"><code>beforescriptexecute</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>script</code> elements
+ <td> Fired at <code>script</code> elements just before the script runs; canceling the event cancels the running of the script
+
+ <tr> <!-- beforeunload -->
+ <td> <dfn data-x="event-beforeunload"><code>beforeunload</code></dfn>
<td> <code>BeforeUnloadEvent</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the page is about to be unloaded, in case the page would like to show a warning prompt
- <tr>
- <td> <code data-x="event-blur">blur</code>
+ <tr> <!-- blur -->
+ <td> <dfn data-x="event-blur"><code>blur</code></dfn>
<td> <code>Event</code>
- <td> Fired at nodes losing focus
+ <td> <code>Window</code>, elements
+ <td> Fired at nodes losing focus <!-- XXX bug 23475 -->
- <tr>
- <td> <code data-x="event-change">change</code>
+ <tr> <!-- cancel -->
+ <td> <dfn data-x="event-cancel"><code>cancel</code></dfn>
<td> <code>Event</code>
- <td> Fired at controls when the user commits a value change
+ <td> <code>dialog</code> elements
+ <td> Fired at <code>dialog</code> elements when they are canceled by the user (e.g. by pressing the Escape key)
- <tr>
+ <tr> <!-- change -->
+ <td> <dfn data-x="event-change"><code>change</code></dfn>
+ <td> <code>Event</code>
+ <td> Form controls
+ <td> Fired at controls when the user commits a value change (see also the <code data-x="event-input-change">change</code> event of <code>input</code> elements)
+
+ <tr> <!-- click -->
<td> <code data-x="event-click">click</code>
+ <td> <code>MouseEvent</code>
+ <td> Elements
+ <td> Normally a mouse event; also synthetically fired at an element before its <span>activation behavior</span> is run, when an element is activated from a non-pointer input device (e.g. a keyboard)
+
+ <tr> <!-- close -->
+ <td> <dfn data-x="event-close"><code>close</code></dfn>
<td> <code>Event</code>
- <td> Fired at an element before its <span>activation behavior</span> is run
+ <td> <code>dialog</code> elements, <code>WebSocket</code>
+ <td> Fired at <code>dialog</code> elments when they are closed, and at <code>WebSocket</code> elements when the connection is terminated
- <tr>
- <td> <code data-x="event-contextmenu">contextmenu</code>
+ <tr> <!-- connnect -->
+ <td> <dfn data-x="event-WorkerGlobalScope-connect"><code>connnect</code></dfn>
+ <td> <code>MessageEvent</code>
+ <td> <code>SharedWorkerGlobalScope</code>
+ <td> Fired at a shared worker's global scope when a new client connects
+
+ <tr> <!-- contextmenu -->
+ <td> <dfn data-x="event-contextmenu"><code>contextmenu</code></dfn>
<td> <code>Event</code>
+ <td> Elements
<td> Fired at elements when the user requests their context menu
- <tr>
- <td> <code data-x="event-DOMContentLoaded">DOMContentLoaded</code>
+ <tr> <!-- error -->
+ <td> <dfn data-x="event-error"><code>error</code></dfn>
<td> <code>Event</code>
- <td> Fired at the <code>Document</code> once the parser has finished
+ <td> Global scope objects, <code>Worker</code> objects, elements, networking-related objects
+ <td> Fired when unexpected errors occur (e.g. networking errors, script errors, decoding errors)
- <tr>
- <td> <code data-x="event-error">error</code>
+ <tr> <!-- focus -->
+ <td> <dfn data-x="event-focus"><code>focus</code></dfn>
<td> <code>Event</code>
- <td> Fired at elements when network and script errors occur
+ <td> <code>Window</code>, elements
+ <td> Fired at nodes gaining focus <!-- XXX bug 23475 -->
- <tr>
- <td> <code data-x="event-focus">focus</code>
- <td> <code>Event</code>
- <td> Fired at nodes gaining focus
-
- <tr>
- <td> <code data-x="event-hashchange">hashchange</code>
+ <tr> <!-- hashchange -->
+ <td> <dfn data-x="event-hashchange"><code>hashchange</code></dfn>
<td> <code>HashChangeEvent</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the fragment identifier part of <span>the document's address</span> changes
- <tr>
- <td> <code data-x="event-input">input</code>
+ <tr> <!-- input -->
+ <td> <dfn data-x="event-input"><code>input</code></dfn>
<td> <code>Event</code>
- <td> Fired at controls when the user changes the value
+ <td> Form controls
+ <td> Fired at controls when the user changes the value (see also the <code data-x="event-input-change">change</code> event of <code>input</code> elements)
- <tr>
- <td> <code data-x="event-invalid">invalid</code>
+ <tr> <!-- invalid -->
+ <td> <dfn data-x="event-invalid"><code>invalid</code></dfn>
<td> <code>Event</code>
+ <td> Form controls
<td> Fired at controls during form validation if they do not satisfy their constraints
- <tr>
- <td> <code data-x="event-load">load</code>
+ <tr> <!-- load -->
+ <td> <dfn data-x="event-load"><code>load</code></dfn>
<td> <code>Event</code>
+ <td> <code>Window</code>, elements
<td> Fired at the <code>Window</code> when the document has finished loading; fired at an element containing a resource (e.g. <code>img</code>, <code>embed</code>) when its resource has finished loading
- <tr>
- <td> <code data-x="event-message">message</code>
+ <tr> <!-- loadend -->
+ <td> <dfn data-x="event-loadend"><code>loadend</code></dfn>
+ <td> <code>Event</code> or <code>ProgressEvent</code>
+ <td> <code>img</code> elements
+ <td> Fired at <code>img</code> elements after a successful load (see also <span data-x="event-media-loadend">media element events</span>)
+
+ <tr> <!-- loadstart -->
+ <td> <dfn data-x="event-loadstart"><code>loadstart</code></dfn>
+ <td> <code>ProgressEvent</code>
+ <td> <code>img</code> elements
+ <td> Fired at <code>img</code> elements when a load begins (see also <span data-x="event-media-loadstart">media element events</span>)
+
+ <tr> <!-- message -->
+ <td> <dfn data-x="event-message"><code>message</code></dfn>
<td> <code>MessageEvent</code>
- <td> Fired at an object when the object receives a message
+ <td> <code>Window</code>, <code>EventSource</code>, <code>WebSocket</code>, <code>MessagePort</code>, <code>BroadcastChannel</code>, <code>DedicatedWorkerGlobalScope</code>, <code>Worker</code>
+ <td> Fired at an object when it receives a message
- <tr>
- <td> <code data-x="event-offline">offline</code>
+ <tr> <!-- offline -->
+ <td> <dfn data-x="event-offline"><code>offline</code></dfn>
<td> <code>Event</code>
- <td> Fired at the <code>Window</code> when the network connections fails
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections fails
- <tr>
- <td> <code data-x="event-online">online</code>
+ <tr> <!-- online -->
+ <td> <dfn data-x="event-online"><code>online</code></dfn>
<td> <code>Event</code>
- <td> Fired at the <code>Window</code> when the network connections returns
+ <td> Global scope objects
+ <td> Fired at the global scope object when the network connections returns
- <tr>
- <td> <code data-x="event-pagehide">pagehide</code>
+ <tr> <!-- open -->
+ <td> <dfn data-x="event-open"><code>open</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>EventSource</code>, <code>WebSocket</code>
+ <td> Fired at networking-related objects when a connection is established
+
+ <tr> <!-- pagehide -->
+ <td> <dfn data-x="event-pagehide"><code>pagehide</code></dfn>
<td> <code>PageTransitionEvent</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the page's entry in the <span>session history</span> stops being the <span>current entry</span>
- <tr>
- <td> <code data-x="event-pageshow">pageshow</code>
+ <tr> <!-- pageshow -->
+ <td> <dfn data-x="event-pageshow"><code>pageshow</code></dfn>
<td> <code>PageTransitionEvent</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the page's entry in the <span>session history</span> becomes the <span>current entry</span>
- <tr>
- <td> <code data-x="event-popstate">popstate</code>
+ <tr> <!-- popstate -->
+ <td> <dfn data-x="event-popstate"><code>popstate</code></dfn>
<td> <code>PopStateEvent</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> when the user navigates the <span>session history</span>
- <tr>
- <td> <code data-x="event-readystatechange">readystatechange</code>
+ <tr> <!-- progress -->
+ <td> <dfn data-x="event-progress"><code>progress</code></dfn>
+ <td> <code>ProgressEvent</code>
+ <td> <code>img</code> elements
+ <td> Fired at <code>img</code> elements during a <span>CORS-same-origin</span> image load (see also <span data-x="event-media-progress">media element events</span>)
+
+ <tr> <!-- readystatechange -->
+ <td> <dfn data-x="event-readystatechange"><code>readystatechange</code></dfn>
<td> <code>Event</code>
+ <td> <code>Document</code>
<td> Fired at the <code>Document</code> when it finishes parsing and again when all its subresources have finished loading
- <tr>
- <td> <code data-x="event-reset">reset</code>
+ <tr> <!-- reset -->
+ <td> <dfn data-x="event-reset"><code>reset</code></dfn>
<td> <code>Event</code>
+ <td> <code>form</code> elements
<td> Fired at a <code>form</code> element when it is <span data-x="concept-form-reset">reset</span>
- <tr>
- <td> <code data-x="event-show">show</code>
+ <tr> <!-- select -->
+ <td> <dfn data-x="event-select"><code>select</code></dfn>
<td> <code>Event</code>
+ <td> Form controls
+ <td> Fired at form controls when an API adjusts the text selection
+
+ <tr> <!-- show -->
+ <td> <dfn data-x="event-show"><code>show</code></dfn>
+ <td> <code>RelatedEvent</code>
+ <td> <code>menu</code> elements
<td> Fired at a <code>menu</code> element when it is shown as a context menu
- <tr>
- <td> <code data-x="event-submit">submit</code>
+ <tr> <!-- sort -->
+ <td> <dfn data-x="event-sort"><code>sort</code></dfn>
<td> <code>Event</code>
+ <td> <code>table</code> elements
+ <td> Fired at <code>table</code> elements before it is sorted; canceling the event cancels the sorting of the table
+
+ <tr> <!-- storage -->
+ <td> <dfn data-x="event-storage"><code>storage</code></dfn>
+ <td> <code>StorageEvent</code>
+ <td> <code>Window</code>
+ <td> Fired at <code>Window</code> event when the corresponding <code data-x="dom-localStorage">localStorage</code> or <code data-x="dom-sessionStorage">sessionStorage</code> storage areas change
+
+ <tr> <!-- submit -->
+ <td> <dfn data-x="event-submit"><code>submit</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>form</code> elements
<td> Fired at a <code>form</code> element when it is <span data-x="concept-form-submit">submitted</span>
- <tr>
- <td> <code data-x="event-unload">unload</code>
+ <tr> <!-- toggle -->
+ <td> <dfn data-x="event-toggle"><code>toggle</code></dfn>
<td> <code>Event</code>
+ <td> <code>details</code> element
+ <td> Fired at <code>details</code> elements when they open or close
+
+ <tr> <!-- unload -->
+ <td> <dfn data-x="event-unload"><code>unload</code></dfn>
+ <td> <code>Event</code>
+ <td> <code>Window</code>
<td> Fired at the <code>Window</code> object when the page is going away
</table>
+<!--CLEANUP-->
<p class="note">See also <a href="#mediaevents">media element
events</a>, <a href="#appcacheevents">application cache events</a>,
and <a href="#dndevents">drag-and-drop events</a>.</p>
-<!--END dev-html-->
-
-<!--START complete--><!--START dev-html-->
<!--START postmsg--><!--START websocket-api--><!--START storage--><!--START eventsource--><!--START workers-->
<h2 class="no-num" id="references">References</h2><!--REFS-->
More information about the Commit-Watchers
mailing list