--- a/html/DOM3-Events.html Thu Feb 18 04:10:48 2010 +0900
+++ b/html/DOM3-Events.html Sun Feb 28 21:42:00 2010 +0900
@@ -20,16 +20,16 @@
</p>
<h1 id="Overview-title">Document Object Model (DOM) Level 3 Events Specification</h1>
<!-- @@@ -->
- <h2 id="Overview-W3C-doctype">W3C Editor's Draft <time datetime="2010-02-08">08 February 2010</time></h2>
+ <h2 id="Overview-W3C-doctype">W3C Editor's Draft <time datetime="2010-02-28">28 February 2010</time></h2>
<dl>
<dt>This version:</dt>
- <dd><a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.120">http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.120</a></dd>
+ <dd><a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.121">http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.121</a></dd>
<dt>Latest stable version:</dt>
<dd><a href="http://www.w3.org/TR/DOM-Level-3-Events">http://www.w3.org/TR/DOM-Level-3-Events</a></dd>
<dt>Previous version:</dt>
- <dd><a href="http://dev.w3.org/cvsweb/~checkout~/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.119">http://dev.w3.org/cvsweb/~checkout~/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.119</a></dd>
+ <dd><a href="http://dev.w3.org/cvsweb/~checkout~/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.120">http://dev.w3.org/cvsweb/~checkout~/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.120</a></dd>
<dt>Editor's Draft:</dt>
<dd><a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html">http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html</a></dd>
@@ -361,7 +361,7 @@
<p><em>This section is normative</em></p>
<p>A conforming DOM Level 3 Events <a class="def" href="#glossary-user-agent">user agent</a> must implement the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method to allow authors to detect for support of features defined in this specification. Refer to <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#DOMFeatures"><em>DOM Features</em></a> in [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>] for additional information on feature strings.</p>
- <p class="note" id=""><strong>Note:</strong> The <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method has been of limited utility to authors in some instances, because of imprecision in conformance criteria in some specifications, and insufficient granularity of feature strings, leading to implementations misrepresenting the degree of support for a class of features. This specification seeks to remedy that in the context of <a class="def" href="#glossary-user-agent">user agents</a> conforming to DOM Level 3 Events by providing discrete feature strings and clear guidelines for the circumstances under which a <a class="def" href="#glossary-user-agent">user agent</a> must or must not report in a positive manner when queried for support of the feature which that feature string represents.</p>
+ <p class="note" id="_0"><strong>Note:</strong> The <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method has been of limited utility to authors in some instances, because of imprecision in conformance criteria in some specifications, and insufficient granularity of feature strings, leading to implementations misrepresenting the degree of support for a class of features. This specification seeks to remedy that in the context of <a class="def" href="#glossary-user-agent">user agents</a> conforming to DOM Level 3 Events by providing discrete feature strings and clear guidelines for the circumstances under which a <a class="def" href="#glossary-user-agent">user agent</a> must or must not report in a positive manner when queried for support of the feature which that feature string represents.</p>
<p>DOM Level 3 Events introduces compositional feature strings, which are base feature strings combined with extended feature strings, a new mechanism for testing support for each specific feature, rather than relying on modules-level feature strings. A <a class="def" href="#glossary-user-agent">user agent</a> conforming to DOM Level 3 Events must also implement the following feature string convention for describing DOM3 Events feature support:</p>
<ul>
<li id="base-feature-string">The primary base feature string for DOM Level 3 Events shall be "<code>Events</code>", with the optional version string "<code>3.0</code>", indicating that the <a class="def" href="#glossary-user-agent">user agent</a> supports the <a href="#conform-arch">DOM Level 3 Events Architecture</a> in the manner described in the appropriate conformance section.
@@ -372,19 +372,19 @@
</li>
<li id="extended-feature-string">The extended feature string for each event type defined in DOM Level 3 Events shall be the base feature string "<code>Events</code>", followed by the period character ("."), followed by the name of that event type, with the optional version string "<code>3.0</code>", indicating that the <a class="def" href="#glossary-user-agent">user agent</a> supports that specific event type in the manner described in the appropriate <a href="#conform-module">conformance section</a>. For example, the feature string for the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event would be "<code>Events.textInput</code>", with the optional version string "<code>3.0</code>".
<ul>
- <li><span class="assert must">Because this specification does not retroactively define extended feature strings for DOM Level 2 Events, using the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method with extended feature strings with a version string "<code>2.0</code>" must return false.</span><span class="warning" id=""><strong>Warning!</strong> Because this mechanism for discrete feature strings was not defined in earlier DOM Events specifications, older user agents which support those specifications but not this one may report false negatives in terms of supporting particular features. For example, a browser which supports the the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type as defined in DOM Level 2 Events, but does not support this specification, is likely to return <code>false</code> to the method call <code>document.implementation.hasFeature("Events.click", "")</code>. The author should not take this for definitive proof that the implementation does not support the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, but rather that other means of testing are required in that instance. This method is best used as a means to detect positive results, not negative ones. However, it is expected that this will prove of sufficient utility in many cases to justify its use.</span></li>
+ <li><span class="assert must">Because this specification does not retroactively define extended feature strings for DOM Level 2 Events, using the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method with extended feature strings with a version string "<code>2.0</code>" must return false.</span><span class="warning" id="_42"><strong>Warning!</strong> Because this mechanism for discrete feature strings was not defined in earlier DOM Events specifications, older user agents which support those specifications but not this one may report false negatives in terms of supporting particular features. For example, a browser which supports the the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type as defined in DOM Level 2 Events, but does not support this specification, is likely to return <code>false</code> to the method call <code>document.implementation.hasFeature("Events.click", "")</code>. The author should not take this for definitive proof that the implementation does not support the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, but rather that other means of testing are required in that instance. This method is best used as a means to detect positive results, not negative ones. However, it is expected that this will prove of sufficient utility in many cases to justify its use.</span></li>
<li><span class="assert must">A <a class="def" href="#glossary-user-agent">user agent</a> which supports an event type in a manner conforming to DOM Level 2 Events but not conforming to DOM Level 3 Events must not report a positive result to that extended feature string, regardless of the value of the version string.</span></li>
<li><span class="assert must">A specification or <a class="def" href="#glossary-host-language">host language</a> which <a href="#conf-specs">conforms</a> to DOM Level 3 Events, and which extends this specification in a manner consistent with the <a href="#conf-extend">extension conformance criteria</a>, may define extended feature strings for event types defined in that specification. These extended feature strings may be used with the feature string "<code>Events</code>".<!-- These extended feature strings may be used with the <a href="#base-feature-string">base feature string</a> of that specification, or with the feature string "<code>Events</code>"; for example, support for the SVG <code>zoom</code> event type might be tested using the method call <code>document.implementation.hasFeature("Events.zoom", "")</code> or the hypothetical <code>document.implementation.hasFeature("SVG.events.zoom", "")</code>. --></span>
- <p class="example" id="example-sync"><strong>Example:</strong> Support for the SVG <code>zoom</code> event type might be tested using the method call <code>document.implementation.hasFeature("Events.zoom", "")</code></p>
+ <p class="example" id="example-zoom"><strong>Example:</strong> Support for the SVG <code>zoom</code> event type might be tested using the method call <code>document.implementation.hasFeature("Events.zoom", "")</code></p>
<!-- <ul>
<li><span class="assert may">A specification or <a class="def" href="#glossary-host-language">host language</a> which extends event types defined in this specification, but which adds functionality to be detected independently. </span></li>
</ul> -->
</li>
</ul>
</li>
- <li>For backwards compatibility, each interface defined in DOM Level 3 Events also has a feature string, which may act as a base feature string or as an extended feature string. If used as a base feature string, it must follow the conventions of the <a href="#base-feature-string">primary base feature string</a> (e.g., "<code>KeyboardEvent</code>", with the optional version string "<code>3.0</code>"); if used as an extended feature string, it must follow the conventions of the <a href="#extended-feature-string">extended feature strings for event types</a> (e.g., "<code>Events.KeyboardEvent</code>", with the optional version string "<code>3.0</code>"). In either case, the <a class="def" href="#glossary-user-agent">user agent</a> must only report a positive result if it supports that specific interface and all associated event types in the manner described in the appropriate <a href="#conform-module">conformance section</a>. <span class="warning" id=""><strong>Warning!</strong> because this is not as specific as testing for a specific event type and may thus be less likely to be accurate, authors are encouraged to use the feature strings for event types rather than interfaces.</span></li>
+ <li>For backwards compatibility, each interface defined in DOM Level 3 Events also has a feature string, which may act as a base feature string or as an extended feature string. If used as a base feature string, it must follow the conventions of the <a href="#base-feature-string">primary base feature string</a> (e.g., "<code>KeyboardEvent</code>", with the optional version string "<code>3.0</code>"); if used as an extended feature string, it must follow the conventions of the <a href="#extended-feature-string">extended feature strings for event types</a> (e.g., "<code>Events.KeyboardEvent</code>", with the optional version string "<code>3.0</code>"). In either case, the <a class="def" href="#glossary-user-agent">user agent</a> must only report a positive result if it supports that specific interface and all associated event types in the manner described in the appropriate <a href="#conform-module">conformance section</a>. <span class="warning" id="_2"><strong>Warning!</strong> because this is not as specific as testing for a specific event type and may thus be less likely to be accurate, authors are encouraged to use the feature strings for event types rather than interfaces.</span></li>
</ul>
- <p class="warning" id=""><strong>Warning!</strong> This specification does not provide a means to guarantee that any given element of a <a class="def" href="#glossary-host-language">host language</a> is capable of generating or dispatching an event of any given <a class="def" href="#glossary-event-type">event type</a> (e.g., an HTML <code>'img'</code> element may not dispatch a <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event), or what the attributes of that event will be beyond those defined in this specification (e.g., the host language may add attributes to the event object). A <a class="def" href="#glossary-host-language">host language</a> may provide a different means to do so, including its own relevant feature strings.</p>
+ <p class="warning" id="_3"><strong>Warning!</strong> This specification does not provide a means to guarantee that any given element of a <a class="def" href="#glossary-host-language">host language</a> is capable of generating or dispatching an event of any given <a class="def" href="#glossary-event-type">event type</a> (e.g., an HTML <code>'img'</code> element may not dispatch a <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event), or what the attributes of that event will be beyond those defined in this specification (e.g., the host language may add attributes to the event object). A <a class="def" href="#glossary-host-language">host language</a> may provide a different means to do so, including its own relevant feature strings.</p>
</div>
@@ -601,7 +601,7 @@
</p>
<p><span class="assert must">As the final step of the event dispatch, for reasons of backwards compatibility, the implementation must reset the event object's internal-propagation and default-action-prevention states.</span> This ensures that an event object may be properly dispatched multiple times while also allowing to prevent the event objects propagation or <a class="def" href="#glossary-default-action">default actions</a> prior to the event dispatch.</p>
<p>In the production of the <a class="def" href="#glossary-propagation-path">propagation path</a>, if the <a class="def" href="#glossary-defaultView">defaultView</a> implements the <a href="#events-Events-EventTarget">EventTarget</a> interface, the event propagates from <a class="def" href="#glossary-defaultView">defaultView</a> to the <code>document</code> object during the <a class="def" href="#glossary-capture-phase">capture phase</a>, and from the <code>document</code> object to the <a class="def" href="#glossary-defaultView">defaultView</a> during the <a class="def" href="#glossary-bubbling-phase">bubble phase</a>.
- <span class="note" id=""><strong>Note:</strong> for legacy reasons, the <a class="eventtype" href="#event-type-load"><code>load</code></a> event does not propagate to the <a class="def" href="#glossary-defaultView">defaultView</a> in HTML implementations.</span></p>
+ <span class="note" id="_4"><strong>Note:</strong> for legacy reasons, the <a class="eventtype" href="#event-type-load"><code>load</code></a> event does not propagate to the <a class="def" href="#glossary-defaultView">defaultView</a> in HTML implementations.</span></p>
<p>The model defined above must be applied regardless of the specific event flow associated with an event target. Each event flow must define how the propagation path shall be determined and which event phases are supported. The <em>DOM event flow</em> is an application of this model: the propagation path for a <code>Node</code> object shall be determined by its <code>Node.parentNode</code> chain, and if applicable, the document's containing <a class="def" href="#glossary-defaultView">defaultView</a>; all events accomplish the capture and target phases; whether an event accomplishes the bubble phase shall be defined individually for each <a class="def" href="#glossary-event-type">event type</a>. An alternate application of this model can be found in [<cite><a class="informative" href="#references-DOMLS">DOM3 Load and Save</a></cite>].</p>
<p>Implementations of the DOM event model must be reentrant. Event listeners may perform actions that cause additional events to be dispatched. Such events are handled in a synchronous manner, the event propagation that causes the event listener to be triggered must resume only after the event dispatch of the new event is completed.</p>
</div>
@@ -627,7 +627,7 @@
<p>Events which are asynchronous may be dispatched as the results of the action are completed, with no relation to other events, to other changes in the DOM, nor to user interaction.</p>
<p class="example" id="example-async">
<strong>Example:</strong>
- <i class="note" id=""><strong>To Do:</strong> Create good example of async events.</i>
+ <i class="note" id="_5"><strong>To Do:</strong> Create good example of async events.</i>
</p>
</div>
<!-- div2 sync-async -->
@@ -643,7 +643,6 @@
<div>
<h3><a id="event-flow-activation" href="#event-flow-activation">3.5 Activation triggers and behavior</a></h3>
- <p class="warning" id="activation-deprecated"><strong>Warning!</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is deprecated in this specification.</p>
<p>Certain <a class="def" href="#glossary-proximal-event-target">proximal event targets</a> (such as a link or button element) may have associated <a class="def" href="#glossary-activation-behavior">activation behavior</a> (such a following a link) that implementations perform in response to an <em><a class="def" href="#glossary-activation-trigger">activation trigger</a></em> (such as clicking a link).</p>
<p>A <a class="def" href="#glossary-host-language">host language</a> should indicate which, if any, elements have activation behavior, describe appropriate <a class="def" href="#glossary-activation-trigger">activation triggers</a>, and define the result of that activation behavior. An implementation which supports a <a class="def" href="#glossary-host-language">host language</a> should initiate these <a class="def" href="#glossary-activation-behavior">activation behavior</a> when the associated <a class="def" href="#glossary-activation-trigger">activation trigger</a> occurs.</p>
<p class="example" id="example-activation"><strong>Example:</strong> Both HTML and SVG have an <code class="element">a</code> element which indicates a link. Relevant <a class="def" href="#glossary-activation-trigger">activation triggers</a> for an <code class="element">a</code> element are a <a class="eventtype" href="#event-type-click"><code>click</code></a> event on the text or image content of the <code class="element">a</code> element, or a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event with a <a href="#events-Events-KeyboardEvent-key">key</a> attribute value of <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> key when the <code class="element">a</code> element has focus. The activation behavior for an <code class="element">a</code> element is normally to change the content of the window to the content of the new document, in the case of external links, or to reposition the current document relative to the new anchor, in the case of internal links.</p>
@@ -659,6 +658,9 @@
<p>Implementations which support the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> should also dispatch a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event as a <a class="def" href="#glossary-default-action">default action</a> of a <a class="eventtype" href="#event-type-click"><code>click</code></a> event which is associated with an <a class="def" href="#glossary-activation-trigger">activation trigger</a>. However, such implementations should only initiate the associated <a class="def" href="#glossary-activation-behavior">activation behavior</a> once for any given occurrence of an <a class="def" href="#glossary-activation-trigger">activation trigger</a>.</p>
<p class="example" id="example-activation-DOMActivate"><strong>Example:</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is required to be supported for XForms [<cite><a class="informative" href="#ref-xforms">XFORMS</a></cite>], which is intended for implementation within a <a class="def" href="#glossary-host-language">host language</a>. In a scenario where a plugin or script-based implementation of XForms is intended for installation in a native implementation of this specification which does not support the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a>, the XForms <a class="def" href="#glossary-user-agent">user agent</a> must synthesize and dispatch its own <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> events based on the appropriate <a class="def" href="#glossary-activation-trigger">activation triggers</a>. Thus, when a <a class="eventtype" href="#event-type-click"><code>click</code></a> event is dispatched by the DOM Level 3 Events <a class="def" href="#glossary-user-agent">user agent</a>, the XForms <a class="def" href="#glossary-user-agent">user agent</a> must determine whether to synthesize a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event with the same relevant properties as a <a class="def" href="#glossary-default-action">default action</a> of that <a class="eventtype" href="#event-type-click"><code>click</code></a> event; appropriate cues may be whether the <a class="eventtype" href="#event-type-click"><code>click</code></a> event is <a href="#trusted-events">trusted</a>, or whether its <a class="def" href="#glossary-proximal-event-target">proximal event target</a> has a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event listener registered.</p>
<p class="note" id="authors-activation"><strong>Note:</strong> Authors should not rely upon the interoperable support of <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> in many <a class="def" href="#glossary-user-agent">user agents</a>. Thus, authors may use the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> whenever they wish to make or react to an <a class="def" href="#glossary-activation-trigger">activation trigger</a>, but should use the <a class="eventtype" href="#event-type-click"><code>click</code></a><a class="def" href="#glossary-event-type">event type</a> for more accessible behavior instead, due to wider implementation.</p>
+
+ <p class="warning" id="activation-deprecated"><strong>Warning!</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is deprecated in this specification.</p>
+
<h4 class="needswork">
<a id="events-activation-event-order" href="#events-activation-event-order">3.5.1 Activation Event Order</a>
</h4>
@@ -914,7 +916,7 @@
<dl>
<dt><strong>Interface <em><a id="events-Events-CustomEvent">CustomEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
<dd>
- <p>The <a id="events-Events-CustomEvent"><code>CustomEvent</code></a> interface is the recommended interface for application-specific event types. Unlike the <a href="#events-Events-Event"><code>Event</code></a> interface, it allows applications to provide contextual information about the event type. Application-specific event types should use a prefix string on the event type name to avoid clashes with future general-purpose event types.</p>
+ <p>The <a href="#events-Events-CustomEvent"><code>CustomEvent</code></a> interface is the recommended interface for application-specific event types. Unlike the <a href="#events-Events-Event"><code>Event</code></a> interface, it allows applications to provide contextual information about the event type. Application-specific event types should use a prefix string on the event type name to avoid clashes with future general-purpose event types.</p>
<p>To create an instance of the <code>CustomEvent</code> interface, use the <a href="#events-Events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("CustomEvent")</code></a> method call.</p>
<dl>
<dt>
@@ -923,7 +925,7 @@
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-CustomEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-CustomEvent">CustomEvent</a> : <a href="#events-Events-Event">Event</a> {
readonly attribute DOMObject <a href="#events-Events-CustomEvent-detail">detail</a>;
@@ -1126,7 +1128,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-EventListener"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Events-EventListener">EventListener</a> {
void <a href="#events-Events-EventListener-handleEvent">handleEvent</a>(in <a href="#events-Events-Event">Event</a> evt);
@@ -1175,7 +1177,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-EventException"><code>
// Introduced in DOM Level 2:
exception <a href="#events-Events-EventException">EventException</a> {
unsigned short code;
@@ -1225,7 +1227,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-DocumentEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Events-DocumentEvent">DocumentEvent</a> {
@@ -1365,7 +1367,7 @@
<p>Creating <a href="#events-Events-Event"><code>Event</code></a> objects that are known to the DOM Events implementation is done using <a href="#events-Events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent()</code></a>. The author must then initialize the <a href="#events-Events-Event"><code>Event</code></a> object by directly setting the <a href="#events-Events-Event"><code>Event</code></a>'s property values, by using the generic <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method, or by using any existing event initialization method for that interface, before invoking <a href="#events-Events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a>. The <a href="#events-Events-Event"><code>Event</code></a> objects created must be known by the DOM Events implementation; otherwise an event exception shall be thrown.</p>
<p class="example" id="example-create-event">
<strong>Example:</strong>
- <i class="note" id=""><strong>To Do:</strong> Create examples of creating and dispatching an event.</i>
+ <i class="note" id="_6"><strong>To Do:</strong> Create examples of creating and dispatching an event.</i>
</p>
</div>
<!-- div3 Events-document -->
@@ -1873,7 +1875,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-UIEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Events-UIEvent">UIEvent</a> : <a href="#events-Events-Event">Event</a> {
readonly attribute views::AbstractView <a href="#events-Events-UIEvent-view">view</a>;
@@ -1960,7 +1962,15 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a button, link, or other state-changing element is activated. Refer to <a href="#event-flow-activation">Activation triggers and behavior</a> for more details.</p>
<p class="warning" id="DOMActivate-deprecated"><strong>Warning!</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related <a class="def" href="#glossary-event-type">event type</a><a class="eventtype" href="#event-type-click"><code>click</code></a>. Other specifications may define and maintain their own <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> for backwards compatibility.</p>
@@ -1984,7 +1994,15 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM implementation finishes loading the resource (such as the document) and any dependent resources (such as images, style sheets, or scripts). Dependent resources that fail to load must not prevent this event from firing if the resource that loaded them is still accessible via the DOM. If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node.</p>
<!-- This event differs from the <a class="eventtype" href="#event-type-DOMContentLoaded"><code>DOMContentLoaded</code></a> event in that it is not dispatched until all external resources are loaded. -->
@@ -2005,7 +2023,15 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM implementation finishes loading the resource (such as the document), but before any dependent resources (such as images, style sheets, or scripts) are necessary loaded. If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node. This event differs from the <a class="eventtype" href="#event-type-load"><code>load</code></a> event in that it is dispatched immediately when the document markup is loaded, rather than waiting on external resources.</p>
@@ -2029,8 +2055,17 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM Implementation removes from the environment the resource (such as the document) or any dependent resources (such as images, style sheets, scripts). The document shall be unloaded after the dispatch of this event type. If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node.</p>
</dd>
</dl>
@@ -2051,8 +2086,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the loading of a resource has been aborted.</p>
</dd>
</dl>
@@ -2073,8 +2117,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a resource failed to load, or has been loaded but cannot be interpreted according to its semantics, such as an invalid image, a script execution error, or non-well-formed XML.</p>
</dd>
</dl>
@@ -2095,8 +2148,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> may be in use</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a user selects some text. This event is dispatched after the selection has occurred.</p>
<p>This specification does not provide contextual information to access the selected text. Where applicable, a <a class="def" href="#glossary-host-language">host language</a> should define rules for how a user may select content (with consideration for international language conventions), at what point the <a class="eventtype" href="#event-type-select"><code>select</code></a> event is dispatched, and how an author may access the user-selected content.</p>
@@ -2125,8 +2187,17 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a document view or an element has been resized. This event type is dispatched after all effects for that occurrence of resizing of that particular <a class="def" href="#glossary-event-target">event target</a> have been executed by the <a class="def" href="#glossary-user-agent">user agent</a>.</p>
<p>In the case of a user-initiated resizing, i.e when a user expands or shrinks a browser window or a resizable element such as <code class="element">object</code> or <code class="element">iframe</code> by dragging the edge of the frame, the frame undergoes several consecutive size changes, but these intermediate stages must not be dispatched as <a class="eventtype" href="#event-type-resize"><code>resize</code></a> events.</p>
<p class="note" id="note-resize-multiple"><strong>Note:</strong> Some <a class="def" href="#glossary-user-agent">user agents</a> may have an optional mode in which the document is reflowed dynamically while the window is resized; in this mode, <a class="eventtype" href="#event-type-resize"><code>resize</code></a> events may be dispatched continuously while the resizing operation is in progress.</p>
@@ -2157,8 +2228,17 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a document view or an element has been scrolled. This event type is dispatched after the scroll has occurred.</p>
</dd>
</dl>
@@ -2177,7 +2257,15 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
<!-- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> attribute indicates the <a href="#events-current-scale-coefficient">current scale coefficient</a> of the <a class="def" href="#glossary-event-target">event target</a>.</td></tr> -->
</table>
@@ -2208,7 +2296,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-FocusEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-FocusEvent">FocusEvent</a> : <a href="#events-Events-UIEvent">UIEvent</a> {
readonly attribute <a href="#events-Events-EventTarget">EventTarget</a> <a href="#events-Events-FocusEvent-relatedTarget">relatedTarget</a>;
@@ -2229,9 +2317,11 @@
<dd>
<p>Used to identify a secondary <a href="#events-Events-EventTarget"><code>EventTarget</code></a> related to a Focus event, depending on the type of event.</p>
- <p class="issue" id="issue-relatedTarget-null-document"><strong>Issue:</strong> Should relatedTarget be null when it would point to an element outside the current document? See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]</p>
+ <p class="issue" id="issue-relatedTarget-null-document"><strong>Issue:</strong> Should relatedTarget be null when it would point to an element outside the current document? See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]
+ For security reasons with nested browsing contexts, when tabbing into or out of a nested context, the relevant EventTarget should be the element containing browsing context (e.g. the <code>iframe</code>), even if that element cannot normally receive focus. Should point to the
+ </p>
- <p class="issue" id="issue-relatedTarget-null-document"><strong>Issue:</strong> Should relatedTarget be null when it points to the same element as 'target'? See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]</p>
+ <p class="issue" id="issue-relatedTarget-null-target"><strong>Issue:</strong> Should relatedTarget be null when it points to the same element as 'target'? See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]</p>
</dd>
</dl>
@@ -2322,7 +2412,16 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> and <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attributes is the <a class="def" href="#glossary-event-target">event target</a> losing focus.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus, <i class="issue" id="issue-blur-relatedTarget"><strong>Issue:</strong> should this be <code>null</code>?</i></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> loses focus. The focus shall be taken from the element before the dispatch of this event type. This event type is similar to <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>, but is dispatched after focus is shifted, and does not bubble.</p>
</dd>
@@ -2344,10 +2443,19 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> and <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attributes is the <a class="def" href="#glossary-event-target">event target</a> receiving focus.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus, <i class="issue" id="issue-DOMFocusIn-relatedTarget"><strong>Issue:</strong> should this be <code>null</code>?</i></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> receives focus. The focus shall be given to the element before the dispatch of this event type. This event type shall be dispatched after the event type <a class="eventtype" href="#event-type-focus"><code>focus</code></a>.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-focus"><code>focus</code></a> and <a class="eventtype" href="#event-type-focusin"><code>focusin</code></a>.</p>
+ <p class="warning" id="_7"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-focus"><code>focus</code></a> and <a class="eventtype" href="#event-type-focusin"><code>focusin</code></a>.</p>
</dd>
</dl>
</div>
@@ -2367,10 +2475,19 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> and <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attributes is the <a class="def" href="#glossary-event-target">event target</a> losing focus.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus, <i class="issue" id="issue-DOMFocusOut-relatedTarget"><strong>Issue:</strong> should this be <code>null</code>?</i></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> loses focus. The focus shall be taken from the element before the dispatch of this event type. This event type shall be dispatched after the event type <a class="eventtype" href="#event-type-blur"><code>blur</code></a>.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>.</p>
+ <p class="warning" id="_8"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>.</p>
</dd>
</dl>
</div>
@@ -2390,7 +2507,16 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> and <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attributes is the <a class="def" href="#glossary-event-target">event target</a> receiving focus.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus, <i class="issue" id="issue-focus-relatedTarget"><strong>Issue:</strong> should this be <code>null</code>?</i></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> receives focus. The focus shall be given to the element before the dispatch of this event type. This event type is similar to <a class="eventtype" href="#event-type-focusin"><code>focusin</code></a>, but is dispatched after focus is shifted, and does not bubble.</p>
</dd>
@@ -2412,10 +2538,19 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> attribute is is the <a class="def" href="#glossary-event-target">event target</a> receiving focus, and the value of the <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attribute is the <a class="def" href="#glossary-event-target">event target</a> losing focus (if any).</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus (if any).</li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> is about to receive focus. This event type must be dispatched before the element is given focus. The <a class="def" href="#glossary-event-target">event target</a> must be the element which is about to receive focus. This event type is similar to <a class="eventtype" href="#event-type-focus"><code>focus</code></a>, but is dispatched before focus is shifted, and does bubble.</p>
- <p class="note" id=""><strong>Note:</strong> When using this event type, the author may use the event's <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attribute (or a host-language-specific method or means) to get the currently focused element before the focus shifts to the next focus <a class="def" href="#glossary-event-target">event target</a>, thus having optional access to both the element losing focus and the element gaining focus without the use of the <a class="eventtype" href="#event-type-blur"><code>blur</code></a> or <a class="eventtype" href="#event-type-focusout">focusout</a> event types.</p>
+ <p class="note" id="_9"><strong>Note:</strong> When using this event type, the author may use the event's <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attribute (or a host-language-specific method or means) to get the currently focused element before the focus shifts to the next focus <a class="def" href="#glossary-event-target">event target</a>, thus having optional access to both the element losing focus and the element gaining focus without the use of the <a class="eventtype" href="#event-type-blur"><code>blur</code></a> or <a class="eventtype" href="#event-type-focusout">focusout</a> event types.</p>
</dd>
</dl>
</div>
@@ -2435,7 +2570,16 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> is in use. The value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> attribute is is the <a class="def" href="#glossary-event-target">event target</a> losing focus, and the value of the <code class="attribute-name"><a href="#events-Events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attribute is the <a class="def" href="#glossary-event-target">event target</a> receiving focus.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus.</li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> is about to lose focus. This event type must be dispatched before the element loses focus. The <a class="def" href="#glossary-event-target">event target</a> must be the element which is about to lose focus. This event type is similar to <a class="eventtype" href="#event-type-blur"><code>blur</code></a>, but is dispatched before focus is shifted, and does bubble.</p>
</dd>
@@ -2443,6 +2587,8 @@
</div>
</div>
<!-- interface events-focusevents -->
+
+
<!-- interface events-mouseevents -->
<div>
<h3><a id="events-mouseevents" href="#events-mouseevents">5.2.3 Mouse Event Types</a></h3>
@@ -2455,14 +2601,14 @@
<p>The <code>MouseEvent</code> interface provides specific contextual information associated with Mouse events.</p>
<p>In the case of nested elements mouse events are always targeted at the most deeply nested element. Ancestors of the targeted element may use bubbling to obtain notification of mouse events which occur within their descendent elements.</p>
<p>To create an instance of the <code>MouseEvent</code> interface, use the <a href="#events-Events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("MouseEvent")</code></a> method call.</p>
- <p class="note" id=""><strong>Note:</strong> When initializing <code>MouseEvent</code> objects using <code>initMouseEvent</code> or <code>initMouseEventNS</code>, implementations should use the client coordinates <code>clientX</code> and <code>clientY</code> for calculation of other coordinates (such as target coordinates exposed by <a class="def" href="#glossary-DOM-Level-0">DOM Level 0</a> implementations or other proprietary attributes, e.g. <code>pageX</code>).</p>
+ <p class="note" id="_10"><strong>Note:</strong> When initializing <code>MouseEvent</code> objects using <code>initMouseEvent</code> or <code>initMouseEventNS</code>, implementations should use the client coordinates <code>clientX</code> and <code>clientY</code> for calculation of other coordinates (such as target coordinates exposed by <a class="def" href="#glossary-DOM-Level-0">DOM Level 0</a> implementations or other proprietary attributes, e.g. <code>pageX</code>).</p>
<dl>
<dt>
<br />
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-MouseEvent"><code>
// Modified in DOM Level 3:
interface <a href="#events-Events-MouseEvent">MouseEvent</a> : <a href="#events-Events-UIEvent">UIEvent</a> {
readonly attribute long <a href="#events-Events-MouseEvent-screenX">screenX</a>;
@@ -2517,7 +2663,7 @@
</dd>
<dt><code class="attribute-name"><a id="events-Events-MouseEvent-buttons">buttons</a></code> of type <code>unsigned short</code>, readonly</dt>
- <dd>During mouse events caused by the depression or release of a mouse button, <code>buttons</code> shall be used to indicate which combination of mouse buttons are currently being pressed, expressed as a bitmask. <span class="note" id=""><strong>Note:</strong> This should not be confused with the <a href="#events-Events-MouseEvent-button">button</a> attribute.</span>
+ <dd>During mouse events caused by the depression or release of a mouse button, <code>buttons</code> shall be used to indicate which combination of mouse buttons are currently being pressed, expressed as a bitmask. <span class="note" id="_11"><strong>Note:</strong> This should not be confused with the <a href="#events-Events-MouseEvent-button">button</a> attribute.</span>
<p>The value of the <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attribute must be as follows:</p>
<ul>
<li><code>0</code> must indicates no button is currently active.</li>
@@ -2525,8 +2671,8 @@
<li><code>2</code> must indicate the secondary button (in general, the right button, often used to display a context menu), if present.</li>
<li><code>4</code> must indicate the auxiliary button (in general, the middle button, often combined with a mouse wheel).</li>
</ul>
- <p>Some pointing devices may provide or simulate more buttons. To represent such buttons, the value must be doubled for each successive button (in the binary series <code>8</code>, <code>16</code>, <code>32</code>, ... ), and the buttons should alternate sides of the device, from left to right. For example, with a 5-button mouse, the primary button (on the left) would have the value <code>1</code>, the secondary button (on the right) would have the value <code>2</code>, the auxiliary button (in the middle) would have the value <code>4</code>, the fourth button (on the left) would have the value <code>8</code>, and the fifth button (on the right) would have the value <code>16</code>. </p>
- <span class="note" id="buttons-mask"><strong>Note:</strong> Because the sum of any set of button values is a unique number, an author can use a bitwise operation to determine how many buttons are currently being pressed and which buttons they are, for an arbitrary number of mouse buttons on a device, e.g. the value <code>3</code> indicates that the left and right button are currently both pressed, while the value <code>5</code> indicates that the left and middle button are currently both pressed.</p>
+ <p>Some pointing devices may provide or simulate more buttons. To represent such buttons, the value must be doubled for each successive button (in the binary series <code>8</code>, <code>16</code>, <code>32</code>, ... ), and the buttons should alternate sides of the device, from left to right. For example, with a 5-button mouse, the primary button (on the left) would have the value <code>1</code>, the secondary button (on the right) would have the value <code>2</code>, the auxiliary button (in the middle) would have the value <code>4</code>, the fourth button (on the left) would have the value <code>8</code>, and the fifth button (on the right) would have the value <code>16</code>.</p>
+ <p class="note" id="buttons-mask"><strong>Note:</strong> Because the sum of any set of button values is a unique number, an author can use a bitwise operation to determine how many buttons are currently being pressed and which buttons they are, for an arbitrary number of mouse buttons on a device, e.g. the value <code>3</code> indicates that the left and right button are currently both pressed, while the value <code>5</code> indicates that the left and middle button are currently both pressed.</p>
</dd>
<dt><code class="attribute-name"><a id="events-Events-MouseEvent-clientX">clientX</a></code> of type <code>long</code>, readonly</dt>
@@ -2652,7 +2798,7 @@
</dl>
<p>The Mouse event types are listed below. In the case of nested elements, mouse event types are always targeted at the most deeply nested element. Ancestors of the targeted element may use bubbling to obtain notification of mouse events which occur within its descendent elements.</p>
<p id="events-dt-current-click-count">Implementations must maintain the <em>current click count</em> when generating mouse events. This shall be a non-negative integer indicating the number of consecutive clicks of a pointing device button during a user action. The notion of consecutive clicks depends on the environment configuration. For example, a <code><a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a></code> event type might not happen if there is a long delay between the two clicks.
- <span class="note" id=""><strong>Note:</strong> The value of <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> for a number of clicks greater than 2 is platform-dependent. For example, on the Windows OS, the click-count series seems to be <code>1, 2, 3, 2, 3</code>, while on MacOS, the click-count series seems to be <code>1, 2, 3, 4, 5, ...</code>.</span></p>
+ <span class="note" id="_12"><strong>Note:</strong> The value of <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> for a number of clicks greater than 2 is platform-dependent. For example, on the Windows OS, the click-count series seems to be <code>1, 2, 3, 2, 3</code>, while on MacOS, the click-count series seems to be <code>1, 2, 3, 4, 5, ...</code>.</span></p>
<!-- click -->
<h4 class="needswork">
<a id="events-mouseevent-event-order" href="#events-mouseevent-event-order">5.2.3.2 Mouse Event Order</a>
@@ -2720,9 +2866,30 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>Varies</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. The <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> attribute indicates the <a href="#events-dt-current-click-count">current click count</a>. The attribute value shall be <code>1</code> when the user begins this action and increments by <code>1</code> for each click.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a>; the attribute value shall be <code>1</code> when the user begins this action and increments by <code>1</code> for each click.</li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
- <p>The <a class="eventtype" href="#event-type-click"><code>click</code></a> event must be dispatched on the <a class="def" href="#glossary-topmost-event-target">topmost event target</a> indicated by the pointer, when the user presses down and releases the pointer button, or otherwise activates the pointer in a manner that simulates such an action. Activation of the button may depend upon the pointer device and the environment configuration, e.g. it may depend on the screen location or the delay between the press and release of the pointing device button. The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be preceded by the <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events on the same element. Depending upon the environment configuration, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be dispatched if one or more of the event types <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>, <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a>, and <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> occur between the press and release of the pointing device button. The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may also be followed by the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
+
+ <p>The <a class="eventtype" href="#event-type-click"><code>click</code></a> event must be dispatched on the <a class="def" href="#glossary-topmost-event-target">topmost event target</a> indicated by the pointer, when the user presses down and releases the pointer button, or otherwise activates the pointer in a manner that simulates such an action. The actuation method of the mouse button must depend upon the pointer device and the environment configuration, e.g. it may depend on the screen location or the delay between the press and release of the pointing device button.</p>
+ <p>The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be preceded by the <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events on the same element. Depending upon the environment configuration, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be dispatched if one or more of the event types <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>, <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a>, and <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> occur between the press and release of the pointing device button. The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may also be followed by the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
<p>In addition to being associated with pointer devices, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type must be dispatched as part of an element activation, as described in <a href="#event-flow-activation">Activation triggers and behavior</a>.</p>
@@ -2782,10 +2949,29 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. The <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> attribute indicates the <a href="#events-dt-current-click-count">current click count</a>.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is clicked twice over an element. The definition of a double click depends on the environment configuration, except that the event target must be the same between <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>, <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, and <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>. This event type must be dispatched after the event type <a class="eventtype" href="#event-type-click"><code>click</code></a> if a click and double click occur simultaneously, and after the event type <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> otherwise.</p>
- <p class="note" id=""><strong>Note:</strong> Canceling the <a class="eventtype" href="#event-type-click"><code>click</code></a> event must not not affect the firing of a <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
+ <p class="note" id="_13"><strong>Note:</strong> Canceling the <a class="eventtype" href="#event-type-click"><code>click</code></a> event must not not affect the firing of a <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
<p>As with the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, the <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event type varies based on the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of the event and the value of the <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a> or <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attributes. Normally, the typical <a class="def" href="#glossary-default-action">default actions</a> of the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event type match those of the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, with the following additional behavior:</p>
<ul>
<li><em>Left click</em> (<a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a> value is <code>0</code>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> value is <code>1</code>):
@@ -2813,8 +2999,28 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. The <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> attribute indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one. For example, if no click happened before the mousedown, <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> must contain the value <code>1</code>.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one. For example, if no click happened before the mousedown, <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> must contain the value <code>1</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is pressed over an element.</p>
</dd>
</dl>
@@ -2835,10 +3041,30 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. <a href="#events-Events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a> indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved onto the boundaries of an element or one of its descendent elements. This event type is similar to <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>, but differs in that it does not bubble, and must not be dispatched when the pointer device moves from an element onto the boundaries of one of its descendent elements.</p>
- <p class="note" id=""><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a><a href="#references-CSS2">[CSS2]</a>. See also the <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a> event type.</p>
+ <p class="note" id="_14"><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a><a href="#references-CSS2">[CSS2]</a>. See also the <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a> event type.</p>
</dd>
</dl>
</div>
@@ -2858,10 +3084,30 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. <a href="#events-Events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a> indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved off of the boundaries of an element and all of its descendent elements. This event type is similar to <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a>, but differs in that does not bubble, and that it must not be dispatched until the pointing device has left the boundaries of the element and the boundaries of all of its children.</p>
- <p class="note" id=""><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a><a href="#references-CSS2">[CSS2]</a>. See also the <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a> event type.</p>
+ <p class="note" id="_15"><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a><a href="#references-CSS2">[CSS2]</a>. See also the <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a> event type.</p>
</dd>
</dl>
</div>
@@ -2881,7 +3127,26 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved while it is over an element. The frequency rate of events while the pointing device is moved shall be implementation-, device-, and platform-specific, but multiple consecutive <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> events should be fired for sustained pointer-device movement, rather than a single event for each instance of mouse movement. Implementations are encouraged to determine the optimal frequency rate to balance responsiveness with performance.</p>
</dd>
@@ -2903,10 +3168,30 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. <a href="#events-Events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a> indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved off of the boundaries of an element. This event type is similar to <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a>, but differs in that does bubble, and that it must be dispatched when the pointer device moves from an element onto the boundaries of one of its descendent elements.</p>
- <p class="note" id=""><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a> event type.</p>
+ <p class="note" id="_16"><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a> event type.</p>
</dd>
</dl>
</div>
@@ -2927,11 +3212,31 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. <a href="#events-Events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a> indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</tbody>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved onto the boundaries of an element. This event type is similar to <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a>, but differs in that does bubble, and that it must be dispatched when the pointer device moves onto the boundaries of an element whose ancestor element is the <a class="def" href="#glossary-event-target">event target</a> for the same event listener instance.</p>
- <p class="note" id=""><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> event type.</p>
+ <p class="note" id="_17"><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> event type.</p>
</dd>
</dl>
</div>
@@ -2951,7 +3256,26 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. The <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> attribute indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one.</li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is released over an element.</p>
</dd>
@@ -2976,7 +3300,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-WheelEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-WheelEvent">WheelEvent</a> : <a href="#events-Events-MouseEvent">MouseEvent</a> {
@@ -3136,13 +3460,34 @@
<table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
<tr class="assert must"><th>Type</th><td class="eventname"><strong><code>wheel</code></strong></td></tr>
<tr class="assert must"><th>Interface</th><td><a href="#events-Events-WheelEvent"><code>WheelEvent</code></a></td></tr>
- <tr class="assert must"><th>Sync / Async</th><td>Async <i class="issue" id="issue-wheel-async"><strong>Issue:</strong> sync/async? See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]</i>
- </td></tr>
+ <tr class="assert must"><th>Sync / Async</th><td>Async</td></tr>
<tr class="assert must"><th>Bubbles</th><td>Yes</td></tr>
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>scroll (or zoom) the document</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-WheelEvent-deltaX"><code>WheelEvent.deltaX</code></a>, <a href="#events-Events-WheelEvent-deltaY"><code>WheelEvent.deltaY</code></a>, <a href="#events-Events-WheelEvent-deltaZ"><code>WheelEvent.deltaZ</code></a>, <a href="#events-Events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>, <a href="#events-Events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>, <a href="#events-Events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>, <a href="#events-Events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>, and <a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a> are in use. <a href="#events-Events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>, <a href="#events-Events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>, <a href="#events-Events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>, <a href="#events-Events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>, and <a href="#events-Events-MouseEvent-button"><code>MouseEvent.button</code></a>, <a href="#events-Events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> are in use if the wheel is associated to a pointing device. <a href="#events-Events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a> indicates the <a class="def" href="#glossary-event-target">event target</a> the pointing device is pointing at, if any. <a href="#events-Events-UIEvent-detail"><code>UIEvent.detail</code></a> is not in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position on the screen, otherwise <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position on the screen, otherwise <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position within the viewport, otherwise <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: if the wheel is associated with a pointing device, the value based on the pointer position within the viewport, otherwise <code>null</code></li>
+ <li><a href="#events-Events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>null</code> <i class="issue" id="issue-wheel-button"><strong>Issue:</strong> in use if the wheel is associated to a pointing device?</i></li>
+ <li><a href="#events-Events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed <i class="issue" id="issue-wheel-buttons"><strong>Issue:</strong> in use if the wheel is associated to a pointing device?</i></li>
+ <li><a href="#events-Events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> the pointing device is pointing at, if any.</li>
+ <li><a href="#events-Events-WheelEvent-deltaX"><code class="attribute-name">WheelEvent.deltaX</code></a>: <code></code></li>
+ <li><a href="#events-Events-WheelEvent-deltaY"><code class="attribute-name">WheelEvent.deltaY</code></a>: <code></code></li>
+ <li><a href="#events-Events-WheelEvent-deltaZ"><code class="attribute-name">WheelEvent.deltaZ</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a mouse wheel has been rotated around any axis, or when an equivalent input device (such as a mouse-ball, certain tablets or touchpads, etc.) has emulated such an action.</p>
<p>The typical default action of the <a class="eventtype" href="#event-type-wheel"><code>wheel</code></a> event type is to scroll (or in some cases, zoom) the document by the indicated amount. If this event is canceled, the implementation must not scroll or zoom the document (or perform whatever other implementation-specific default action is associated with this event type).</p>
@@ -3182,6 +3527,8 @@
</dd>
</dl>
</div>
+
+
<!-- div3 Events-eventgroupings-textevents -->
<div>
<h3><a id="events-textevents" href="#events-textevents">5.2.5 Text Events Types</a></h3>
@@ -3199,7 +3546,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-TextEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-TextEvent">TextEvent</a> : <a href="#events-Events-UIEvent">UIEvent</a> {
@@ -3347,7 +3694,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, <a href="#events-Events-TextEvent-data"><code>TextEvent.data</code></a>, and <a href="#events-Events-TextEvent-inputMode"><code>TextEvent.inputMode</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-TextEvent-data"><code class="attribute-name">TextEvent.data</code></a>: <code></code></li>
+ <li><a href="#events-Events-TextEvent-inputMode"><code class="attribute-name">TextEvent.inputMode</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when one or more characters have been entered. These characters may originate from a variety of sources, e.g., characters resulting from a key being pressed or released on a keyboard device, from the processing of an <a class="def" href="#glossary-ime">input method editor</a>, or resulting from a voice command. Where a "paste" operation generates a simple sequence of characters, i.e. a text passage without any structure or style information, this event type should be generated as well.</p>
</dd>
@@ -3372,7 +3729,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-KeyboardEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-KeyboardEvent">KeyboardEvent</a> : <a href="#events-Events-UIEvent">UIEvent</a> {
@@ -3414,22 +3771,22 @@
<dd>
<dl>
<dt><a id="events-DOM_KEY_LOCATION_LEFT"><code class="constant-name">DOM_KEY_LOCATION_LEFT</code></a></dt>
- <dd>The key activated shall be in the left key location (there is more than one possible location for this key). <i class="example" id=""><strong>Example:</strong> the left <code class="value">'Control'</code> key on a PC 101 Key US keyboard.</i></dd>
+ <dd>The key activated shall be in the left key location (there is more than one possible location for this key). <i class="example" id="_18"><strong>Example:</strong> the left <code class="value">'Control'</code> key on a PC 101 Key US keyboard.</i></dd>
<dt><a id="events-DOM_KEY_LOCATION_NUMPAD"><code class="constant-name">DOM_KEY_LOCATION_NUMPAD</code></a></dt>
- <dd>The key activation originated on the numeric keypad or with a virtual key corresponding to the numeric keypad. <i class="example" id=""><strong>Example:</strong> the <code class="value">'1'</code> key on a PC 101 Key US keyboard located on the numeric pad.</i></dd>
+ <dd>The key activation originated on the numeric keypad or with a virtual key corresponding to the numeric keypad. <i class="example" id="_19"><strong>Example:</strong> the <code class="value">'1'</code> key on a PC 101 Key US keyboard located on the numeric pad.</i></dd>
<dt><a id="events-DOM_KEY_LOCATION_RIGHT"><code class="constant-name">DOM_KEY_LOCATION_RIGHT</code></a></dt>
- <dd>The key activation shall be in the right key location (there is more than one possible location for this key). <i class="example" id=""><strong>Example:</strong> the right <code class="value">'Shift'</code> key on a PC 101 Key US keyboard.</i></dd>
+ <dd>The key activation shall be in the right key location (there is more than one possible location for this key). <i class="example" id="_21"><strong>Example:</strong> the right <code class="value">'Shift'</code> key on a PC 101 Key US keyboard.</i></dd>
<dt><a id="events-DOM_KEY_LOCATION_STANDARD"><code class="constant-name">DOM_KEY_LOCATION_STANDARD</code></a></dt>
- <dd>The key activation shall not be distinguished as the left or right version of the key, and did not originate from the numeric keypad (or did not originate with a virtual key corresponding to the numeric keypad). <i class="example" id=""><strong>Example:</strong> the <code class="value">'Q'</code> key on a PC 101 Key US keyboard.</i></dd>
+ <dd>The key activation shall not be distinguished as the left or right version of the key, and did not originate from the numeric keypad (or did not originate with a virtual key corresponding to the numeric keypad). <i class="example" id="_22"><strong>Example:</strong> the <code class="value">'Q'</code> key on a PC 101 Key US keyboard.</i></dd>
<dt><a id="events-DOM_KEY_LOCATION_MOBILE"><code class="constant-name">DOM_KEY_LOCATION_MOBILE</code></a></dt>
- <dd>The key activation originated on a mobile device, either on a physical keypad or a virtual keyboard. <i class="example" id=""><strong>Example:</strong> the <code class="value">'#'</code> key or softkey on a mobile device.</i></dd>
+ <dd>The key activation originated on a mobile device, either on a physical keypad or a virtual keyboard. <i class="example" id="_23"><strong>Example:</strong> the <code class="value">'#'</code> key or softkey on a mobile device.</i></dd>
<dt><a id="events-DOM_KEY_LOCATION_JOYSTICK"><code class="constant-name">DOM_KEY_LOCATION_JOYSTICK</code></a></dt>
- <dd>The key activation originated on a game controller or a joystick on a mobile device. <i class="example" id=""><strong>Example:</strong> the <code class="value">'DownLeft'</code> key on a game controller.</i></dd>
+ <dd>The key activation originated on a game controller or a joystick on a mobile device. <i class="example" id="_24"><strong>Example:</strong> the <code class="value">'DownLeft'</code> key on a game controller.</i></dd>
</dl>
</dd>
@@ -3441,7 +3798,7 @@
<dl>
<dt><code class="attribute-name"><a id="events-Events-KeyboardEvent-altKey">altKey</a></code> of type <code>boolean</code>, readonly</dt>
<dd><code>true</code> if the alternative (Alt) key modifier is activated.
- <p class="note" id=""><strong>Note:</strong> The Option key modifier on Macintosh systems must be represented using this key modifier.</p></dd>
+ <p class="note" id="_25"><strong>Note:</strong> The Option key modifier on Macintosh systems must be represented using this key modifier.</p></dd>
<dt><code class="attribute-name"><a id="events-Events-KeyboardEvent-ctrlKey">ctrlKey</a></code> of type <code>boolean</code>, readonly</dt>
<dd><p><code>true</code> if the control (Ctrl) key modifier is activated.</p></dd>
@@ -3454,7 +3811,7 @@
<dt><code class="attribute-name"><a id="events-Events-KeyboardEvent-metaKey">metaKey</a></code> of type <code>boolean</code>, readonly</dt>
<dd><code>true</code> if the meta (Meta) key modifier is activated.
- <p class="note" id=""><strong>Note:</strong> The Command key modifier on Macintosh systems must be represented using this key modifier.</p></dd>
+ <p class="note" id="_26"><strong>Note:</strong> The Command key modifier on Macintosh systems must be represented using this key modifier.</p></dd>
<dt><code class="attribute-name"><a id="events-Events-KeyboardEvent-shiftKey">shiftKey</a></code> of type <code>boolean</code>, readonly</dt>
<dd><p><code>true</code> if the shift (Shift) key modifier is activated.</p></dd>
@@ -3494,7 +3851,7 @@
<code class="value">'Shift'</code>, and
<code class="value">'Win'</code>.
User agents may support additional implementation-specific modifier keys depending on the environment.</p>
- <p class="note" id=""><strong>Note:</strong> If an application wishes to distinguish between right and left modifiers, this information could be deduced using keyboard events and <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>.</p>
+ <p class="note" id="_27"><strong>Note:</strong> If an application wishes to distinguish between right and left modifiers, this information could be deduced using keyboard events and <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>.</p>
</dd>
</dl>
</div>
@@ -3604,7 +3961,7 @@
</li>
</ol>
<p class="note" id="key-default"><strong>Note:</strong> Typically, any <a class="def" href="#glossary-default-action">default actions</a> associated with any particular key must be completed before the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event is dispatched, which may delay the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event slightly (though this is not likely to be a perceptible delay).</p>
- <p class="warning" id=""><strong>Warning!</strong> Because of hardware limitations, on some keyboard devices, the order between the text event and keyboard events may differ. For example, some mobile devices may dispatch the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event after the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event.</p>
+ <p class="warning" id="_28"><strong>Warning!</strong> Because of hardware limitations, on some keyboard devices, the order between the text event and keyboard events may differ. For example, some mobile devices may dispatch the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event after the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event.</p>
<!-- keydown -->
<div class="event-definition assert must">
@@ -3621,7 +3978,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>Varies: <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a>, <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>, <a href="#events-Events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a>, <a href="#events-Events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a>, <a href="#events-Events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a>, <a href="#events-Events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a>, and <a href="#events-Events-KeyboardEvent-repeat"><code>KeyboardEvent.repeat</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-repeat"><code class="attribute-name">KeyboardEvent.repeat</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is pressed down. The <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. This event type shall be generated after the keyboard mapping but before the processing of an <a class="def" href="#glossary-ime">input method editor</a>, normally associated with the dispatching of a <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>, <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>, or <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event. This event type must be dispatched before the <a class="eventtype" href="#event-type-compositionstart"><code>keypress</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events event associated with the same key. Whether or not a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> contributes to the generation of a text event is implementation dependent.</p>
<p>The default action of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event depends upon the key:</p>
@@ -3637,7 +4009,7 @@
<!-- <li>if the key is associated with any other event type, such as the <a class="eventtype" href="#event-type-scroll"><code>scroll</code></a> event, the default action shall be to dispatch an event of that type.</li> -->
</ul>
<p>If this event is canceled, the associated events types must not be dispatched, and the associated actions must not be performed.</p>
- <p class="note" id=""><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
+ <p class="note" id="_29"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
</dd>
</dl>
</div>
@@ -3657,11 +4029,26 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>Varies: <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a>, <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>, <a href="#events-Events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a>, <a href="#events-Events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a>, <a href="#events-Events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a>, <a href="#events-Events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a>, and <a href="#events-Events-KeyboardEvent-repeat"><code>KeyboardEvent.repeat</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-repeat"><code class="attribute-name">KeyboardEvent.repeat</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is pressed down, if and only if that key normally produces a <a class="def" href="#glossary-character-value">character value</a>. The <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. This event type shall be generated after the keyboard mapping but before the processing of an <a class="def" href="#glossary-ime">input method editor</a>, normally associated with the dispatching of a <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>, <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>, or <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event. This event type must be dispatched after the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event and before the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event associated with the same key.</p>
- <p class="note" id=""><strong>Note:</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event is traditionally associated with detecting a <a class="def" href="#glossary-character-value">character value</a> rather than a physical key, and may not be available on all keys in some configurations.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event type.</p>
+ <p class="note" id="_31"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event is traditionally associated with detecting a <a class="def" href="#glossary-character-value">character value</a> rather than a physical key, and may not be available on all keys in some configurations.</p>
+ <p class="warning" id="_32"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event type.</p>
</dd>
</dl>
</div>
@@ -3681,10 +4068,24 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a>, and <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> are in use. <a href="#events-Events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a>, <a href="#events-Events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a>, <a href="#events-Events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a>, and <a href="#events-Events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a> are in use unless the <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> corresponds to the key modifier itself.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: <code></code></li>
+ <li><a href="#events-Events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>: <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>: <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> key is depressed, otherwise <code>false</code></li>
+ <li><a href="#events-Events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>: <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> key is depressed, otherwise <code>false</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is released. The <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. This event type shall be generated after the keyboard mapping. This event type must be dispatched after the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> events event associated with the same key. Whether or not a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> contributes to the generation of a text event is implementation dependent.</p>
- <p class="note" id=""><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
+ <p class="note" id="_33"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
</dd>
</dl>
</div>
@@ -3708,7 +4109,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-CompositionEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-CompositionEvent">CompositionEvent</a> : <a href="#events-Events-UIEvent">UIEvent</a> {
readonly attribute DOMString <a href="#events-Events-CompositionEvent-data">data</a>;
@@ -3815,11 +4216,21 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td>Launch <a class="def" href="#glossary-text-composition-system">text composition system</a></td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, and <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a>.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> is invoked in preparation for composing a passage of text. This event type is device-dependent, and may rely upon the capabilities of the text conversion system and how it is mapped into the operating system. When a keyboard is used to feed an input method editor, this event type is generated after a <code>keydown</code> event, but speech or handwriting recognition systems may send this event type without keyboard events. Some implemenations may populate the <a href="#events-Events-CompositionEvent-data"><code>data</code></a> attribute of the <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a> event with the text currently selected in the document (for editing and replacement); otherwise, the value of the <a href="#events-Events-CompositionEvent-data"><code>data</code></a> attribute shall be <code>null</code>.</p>
<p>This event is dispatched immediately before a <a class="def" href="#glossary-text-composition-system">text composition system</a> is launched. The default action of this event is to launch the appropriate <a class="def" href="#glossary-text-composition-system">text composition system</a>. If this event is canceled, the <a class="def" href="#glossary-text-composition-system">text composition system</a> must not be launched.</p>
- <p>(<i class="issue" id="issue-composition_events"><strong>Issue:</strong> see <a href="http://lists.w3.org/Archives/Public/www-dom/2009JulSep/0143.html" title="Extra notes on composition events from Daniel Danilatos on 2009-08-07 (www-dom@w3.org from July to September 2009)">Extra notes on composition events</a> for more details.</i>)</p>
+ <!-- <p>(<i class="issue" id="issue-composition_events"><strong>Issue:</strong> see <a href="http://lists.w3.org/Archives/Public/www-dom/2009JulSep/0143.html" title="Extra notes on composition events from Daniel Danilatos on 2009-08-07 (www-dom@w3.org from July to September 2009)">Extra notes on composition events</a> for more details.</i>)</p> -->
</dd>
</dl>
</div>
@@ -3839,7 +4250,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, and <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a>.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: <code></code></li>
+
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> should dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> updates its active text passage with a new character, which is added to the string in <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a>. Note that some <a class="def" href="#glossary-text-composition-system">text composition systems</a> may not expose this information to the DOM, in which case this event will not fire during the composition process. If the composition session is canceled, this event will be fired immediately before the <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event, and the <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a> attribute will be set to <code>null</code>.</p>
</dd>
@@ -3861,7 +4282,17 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>Yes</td></tr>
<tr class="assert must"><th>Default action</th><td><a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-UIEvent-view"><code>UIEvent.view</code></a>, and <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a>.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
+ <li><a href="#events-Events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: <code></code></li>
+
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> completes the composition of its active text passage, or cancels the composition process. If the result of the <a class="def" href="#glossary-text-composition-system">text composition system</a> is not null and does not contain the empty string, this event type will be followed by a <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event type with the appropriate <a href="#events-Events-TextEvent-inputMode">inputMode</a> value, such as <a href="#events-DOM_INPUT_METHOD_IME">DOM_INPUT_METHOD_IME</a>, <a href="#events-DOM_INPUT_METHOD_HANDWRITING">DOM_INPUT_METHOD_HANDWRITING</a>, <a href="#events-DOM_INPUT_METHOD_VOICE">DOM_INPUT_METHOD_VOICE</a>, or <a href="#events-DOM_INPUT_METHOD_MULTIMODAL">DOM_INPUT_METHOD_MULTIMODAL</a>.</p>
<p>This event is dispatched immediately after the <a class="def" href="#glossary-text-composition-system">text composition system</a> is completed (e.g. the <a class="def" href="#glossary-ime">IME</a> closed, minimized, switched out of focus, or otherwise dismissed, with the focus switched back to the <a class="def" href="#glossary-user-agent">user agent</a>). The default action of this event is to dispatch the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event type as described above. If this event is canceled, the <a class="eventtype" href="#event-type-textInput"><code>textInput</code></a> event type must not be dispatch, no matter the value of the <a href="#events-Events-CompositionEvent-data"><code>CompositionEvent.data</code></a> attribute. Note that canceling the <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> <em>event type</em> is distinct from canceling the <a class="def" href="#glossary-text-composition-system">text composition system</a> session (e.g. by hitting a cancel button or closing an <a class="def" href="#glossary-ime">IME</a> window).</p>
@@ -3895,7 +4326,7 @@
<!-- <p class="issue">Note that nodes that are not in the document, such as elements freshly created, or elements removed from the DOM, shall not fire mutation events when changed. For example, if an element is created but not yet inserted into the document, then an existing element located in the document shall be moved from its current location to be a child of the new element, there must be one mutation event, for removing the existing element from its previous location, but no event must fire for insertion of the element into the new element, regardless of any assigned mutation event listeners.</p>
<p class="issue">?What happens to event listeners on an element when it is removed from the tree, or moved elsewhere in the tree?</p> -->
<p>Many single modifications of the tree can cause multiple mutation events to be dispatched. Rather than attempt to specify the ordering of mutation events due to every possible modification of the tree, the ordering of these events is left to the implementation.</p>
- <p class="warning" id=""><strong>Warning!</strong> The <a href="#events-Events-MutationEvent">MutationEvent interface</a> was introduced in DOM Level 2 Events, but has not yet been completely and interoperably implemented across <a class="def" href="#glossary-user-agent">user agents</a>. In addition, there have been critiques that the interface, as designed, introduces a performance and implementation challenge. A new specification is under development with the aim of addressing the use cases that mutation events solves, but in more performant manner. Thus, this specification describes mutation events for reference and completeness of legacy behavior, but <a class="def" href="#glossary-deprecated">deprecates</a> the use of both the <a href="#events-Events-MutationEvent"><code>MutationEvent</code></a> interface and the <a href="#events-Events-MutationNameEvent"><code>MutationNameEvent</code></a> interface.</p>
+ <p class="warning" id="_34"><strong>Warning!</strong> The <a href="#events-Events-MutationEvent">MutationEvent interface</a> was introduced in DOM Level 2 Events, but has not yet been completely and interoperably implemented across <a class="def" href="#glossary-user-agent">user agents</a>. In addition, there have been critiques that the interface, as designed, introduces a performance and implementation challenge. A new specification is under development with the aim of addressing the use cases that mutation events solves, but in more performant manner. Thus, this specification describes mutation events for reference and completeness of legacy behavior, but <a class="def" href="#glossary-deprecated">deprecates</a> the use of both the <a href="#events-Events-MutationEvent"><code>MutationEvent</code></a> interface and the <a href="#events-Events-MutationNameEvent"><code>MutationNameEvent</code></a> interface.</p>
<dl>
<dt><strong>Interface <em><a id="events-Events-MutationEvent">MutationEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
<dd>
@@ -3907,7 +4338,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-MutationEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Events-MutationEvent">MutationEvent</a> : <a href="#events-Events-Event">Event</a> {
@@ -4048,10 +4479,22 @@
<tr class="assert must"><th>Target</th><td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>DocumentFragment</code>, <code>Element</code>, <code>Attr</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td>None</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>This is a general event for notification of all changes to the document. It can be used instead of the more specific mutation and mutation name events listed below. It may be dispatched after a single modification to the document or, at the implementation's discretion, after multiple changes have occurred. The latter use should generally be used to accommodate multiple changes which occur either simultaneously or in rapid succession. The target of this event shall be the lowest common parent of the changes which have taken place. This event shall be dispatched after any other events caused by the mutation(s) have occurred.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMSubtreeModified"><code>DOMSubtreeModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_35"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMSubtreeModified"><code>DOMSubtreeModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4071,10 +4514,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationEvent-relatedNode"><code>MutationEvent.relatedNode</code></a> holds the parent node of the node that has been inserted or, in case of <code>Attr</code> nodes, the <code>ownerElement</code> of the <code>Attr</code> node.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the parent node of the node that has been inserted or, in case of <code>Attr</code> nodes, the <code>ownerElement</code> of the <code>Attr</code> node.</li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node has been added as a child of another node or, in case of <code>Attr</code> nodes, has been added to an <code>Element</code>. This event shall be dispatched after the insertion has taken place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the node being inserted.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_36"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4094,10 +4549,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationEvent-relatedNode"><code>MutationEvent.relatedNode</code></a> holds the parent node of the node being removed or, in case of <code>Attr</code> nodes, the <code>ownerElement</code> of the <code>Attr</code> node.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the parent node of the node being removed or, in case of <code>Attr</code> nodes, the <code>ownerElement</code> of the <code>Attr</code> node.</li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node is being removed from its parent node or, in case of <code>Attr</code> nodes, removed from its <code>ownerElement</code>. This event shall be dispatched before the removal takes place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the node being removed.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_37"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4117,10 +4584,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td>None</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node is being removed from a document, either through direct removal of the node or removal of a subtree in which it is contained; <code>Attr</code> nodes are considered part of an <code>Element</code>'s subtree. This event shall be dispatched before the removal takes place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event type shall be the node being removed. If the node is being directly removed, the event type <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> must occur before this event type.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument"><code>DOMNodeRemovedFromDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_38"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument"><code>DOMNodeRemovedFromDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4140,10 +4619,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td>None</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node has been inserted into a document, either through direct insertion of the node or insertion of a subtree in which it is contained; <code>Attr</code> nodes are considered part of an <code>Element</code>'s subtree. This event shall be dispatched after the insertion has taken place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the node being inserted. If the node is being directly inserted, the event type <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> must occur before this event type.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument"><code>DOMNodeInsertedIntoDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_39"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument"><code>DOMNodeInsertedIntoDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4163,10 +4654,22 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationEvent-attrName"><code>MutationEvent.attrName</code></a> and <a href="#events-Events-MutationEvent-attrChange"><code>MutationEvent.attrChange</code></a> are in use. The value of <a href="#events-Events-MutationEvent-relatedNode"><code>MutationEvent.relatedNode</code></a> indicates the <code>Attr</code> node that has been modified, added, or removed. If the <code>Attr</code> node has been added, <a href="#events-Events-MutationEvent-newValue"><code>MutationEvent.newValue</code></a> shall be in use. If the <code>Attr</code> node has been removed, <a href="#events-Events-MutationEvent-prevValue"><code>MutationEvent.prevValue</code></a> shall be in use. If the <code>Attr</code> node has been modified, <a href="#events-Events-MutationEvent-newValue"><code>MutationEvent.newValue</code></a> and <a href="#events-Events-MutationEvent-prevValue"><code>MutationEvent.prevValue</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code></code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code></code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: indicates the <code>Attr</code> node that has been modified, added, or removed.</li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: if the <code>Attr</code> node has been added or modified</li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: if the <code>Attr</code> node has been removed or modified</li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after an <code>Attr.value</code> has been modified and after an <code>Attr</code> node has been added to or removed from an <code>Element</code>. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the <code>Element</code> node where the change occurred. It is implementation dependent whether this event type occurs when the children of the <code>Attr</code> node are changed in ways that do not affect the value of <code>Attr.value</code>.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_44"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4186,10 +4689,21 @@
<tr class="assert must"><th>Target</th><td><code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>ProcessingInstruction</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationEvent-prevValue"><code>MutationEvent.prevValue</code></a>, and <a href="#events-Events-MutationEvent-newValue"><code>MutationEvent.newValue</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ </ul>
+ </td>
+ </tr>
</table>
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after <code>CharacterData.data</code> or <code>ProcessingInstruction.data</code> have been modified, but the node itself has not been inserted or deleted. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the <code>CharacterData</code> node or the <code>ProcessingInstruction</code> node.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_45"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4199,7 +4713,7 @@
<h3><a id="events-mutationnameevents" href="#events-mutationnameevents">5.2.9 Mutation Name Event Types</a></h3>
<p>This module defines the feature MutationNameEvents 3.0 and depends on the features MutationEvents 3.0 and Core 3.0.</p>
- <p class="warning" id=""><strong>Warning!</strong> The <code>MutationNameEvent</code> interface, introduced in an earlier draft of this specification, derives from the <a href="#events-mutationevents"><code>MutationEvent</code></a> interface, which is deprecated in this specification. Thus, this specification describes the mutation name event types for completeness, but <a class="def" href="#glossary-deprecated">deprecates</a> their use.</p>
+ <p class="warning" id="_46"><strong>Warning!</strong> The <code>MutationNameEvent</code> interface, introduced in an earlier draft of this specification, derives from the <a href="#events-mutationevents"><code>MutationEvent</code></a> interface, which is deprecated in this specification. Thus, this specification describes the mutation name event types for completeness, but <a class="def" href="#glossary-deprecated">deprecates</a> their use.</p>
<dl>
<dt><strong>Interface <em><a id="events-Events-MutationNameEvent">MutationNameEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
<dd>
@@ -4211,7 +4725,7 @@
<strong>IDL Definition</strong>
</dt>
<dd>
- <pre class="idl" id="idl-interface-"><code>
+ <pre class="idl" id="idl-interface-MutationNameEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-Events-MutationNameEvent">MutationNameEvent</a> : <a href="#events-Events-MutationEvent">MutationEvent</a> {
readonly attribute DOMString <a href="#events-Events-MutationNameEvent-prevNamespaceURI">prevNamespaceURI</a>;
@@ -4299,10 +4813,24 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationNameEvent-prevNamespaceURI"><code>MutationNameEvent.prevNamespaceURI</code></a>, and <a href="#events-Events-MutationNameEvent-prevNodeName"><code>MutationNameEvent.prevNodeName</code></a> are in use.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationNameEvent-prevNamespaceURI"><code class="attribute-name">MutationNameEvent.prevNamespaceURI</code></a>: <code></code></li>
+ <li><a href="#events-Events-MutationNameEvent-prevNodeName"><code class="attribute-name">MutationNameEvent.prevNodeName</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after the <code>namespaceURI</code> and/or the <code>nodeName</code> of an <code>Element</code> node have been modified (e.g., the element was renamed using <code>Document.renameNode()</code>). The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the renamed <code>Element</code> node.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMElementNameChanged"><code>DOMElementNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_47"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMElementNameChanged"><code>DOMElementNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4322,10 +4850,24 @@
<tr class="assert must"><th>Target</th><td><code>Element</code></td></tr>
<tr class="assert must"><th>Cancelable</th><td>No</td></tr>
<tr class="assert must"><th>Default action</th><td>none</td></tr>
- <tr class="assert must"><th>Context info</th><td><a href="#events-Events-MutationNameEvent-prevNamespaceURI"><code>MutationNameEvent.prevNamespaceURI</code></a>, and <a href="#events-Events-MutationNameEvent-prevNodeName"><code>MutationNameEvent.prevNodeName</code></a> are in use. The value of <a href="#events-Events-MutationEvent-relatedNode"><code>MutationEvent.relatedNode</code></a> contains the renamed <code>Attr</code> node.</td></tr>
+ <tr class="assert must"><th>Context info</th>
+ <td>
+ <ul>
+ <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
+ <li><a href="#events-Events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the renamed <code>Attr</code> node.</li>
+ <li><a href="#events-Events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: <code>null</code></li>
+ <li><a href="#events-Events-MutationNameEvent-prevNamespaceURI"><code class="attribute-name">MutationNameEvent.prevNamespaceURI</code></a>: <code></code></li>
+ <li><a href="#events-Events-MutationNameEvent-prevNodeName"><code class="attribute-name">MutationNameEvent.prevNodeName</code></a>: <code></code></li>
+ </ul>
+ </td>
+ </tr>
</table>
+
<p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after the <code>namespaceURI</code> and/or the <code>nodeName</code> of a <code>Attr</code> node have been modified (e.g., the attribute was renamed using <code>Document.renameNode()</code>). The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event shall be the <code>Element</code> node whose <code>Attr</code> has been renamed.</p>
- <p class="warning" id=""><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttributeNameChanged"><code>DOMAttributeNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
+ <p class="warning" id="_48"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttributeNameChanged"><code>DOMAttributeNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
</dd>
</dl>
</div>
@@ -4343,7 +4885,7 @@
<li>Relations between keyboard events, their default actions, and text events.</li>
<li>The set of key values, and guidelines on how to extend this set.</li>
</ul>
- <p class="note" id=""><strong>Note:</strong> This section uses Serbian and Kanji characters which are not always available (or are misrepresented) in the alternative versions or printed versions of this specification.</p>
+ <p class="note" id="_49"><strong>Note:</strong> This section uses Serbian and Kanji characters which are not always available (or are misrepresented) in the alternative versions or printed versions of this specification.</p>
<div>
<h3><a id="keyboard-input" href="#keyboard-input">6.1 Keyboard Input</a></h3>
@@ -4367,11 +4909,11 @@
<p>As with the key labels, the physical layout of the keys on the keyboard does not not affect the digital key value for any given key. It is outside the scope of this specification to provide key values based on keyboard layout, particularly since there are so many possible layouts for a keyboard, and since users can change the mapping of keys in their operating system, e.g. by selecting a Dvorak key mapping.</p>
<p>To illustrate the concept of keyboard layout mappings and its relation with keyboard events and key values, on the same keyboard (a PC/AT US keyboard), pressing the key labeled <code>Q</code> (with no modifier key activated) will produce different key values based on the mapping. With a typical US <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard layout mapping, it will produce <code class="value">'q'</code> (<code class="value">'\u0071'</code>, Latin Small Letter Q). If the keyboard layout mapping is switched to a French mapping, pressing the same key will produce <code class="value">'a'</code> (<code class="value">'\u0041'</code>, Latin Capital Letter A). If the keyboard layout mapping is switched to a Serbian (Cyrillic) mapping, pressing the same key will produce <code class="value">'љ'</code> (<code class="value">'\u0459'</code>, Cyrillic Small Letter LJE).</p>
<p>However, the physical layout of the keys may be of interest to authors developing games or other applications wherein the location of the keys has an ergonomic relationship as the desired user interface controls, with little or no attention paid to the representational value of the key itself. For example, many games may use the keys <code class="value">'A'</code>, <code class="value">'S'</code>, <code class="value">'D'</code>, and <code class="value">'W'</code> for <code class="value">'left'</code>, <code class="value">'down'</code>, <code class="value">'right'</code>, and <code class="value">'up'</code> respectively. Authors should provide a means for the user to assign such controller keys to a custom setting appropriate to their keyboard configurations. Implementations may provide a means for the user to more comprehensively map the keyboard to their customized keyboard layout, but this is beyond the scope of this specification.</p>
- <p class="note" id=""><strong>Note:</strong> Key values should not be confused with <em>scan codes</em>, which are the low-level hexadecimal signals produced for each key by the keyboard driver software, and which are mapped at the operating system to a <acronym title="Virtual Key">VK</acronym> ("virtual key"), which in turn may be mapped to the user-defined key configuration. Key values are a high-level abstraction of that final mapping.</p>
+ <p class="note" id="_60"><strong>Note:</strong> Key values should not be confused with <em>scan codes</em>, which are the low-level hexadecimal signals produced for each key by the keyboard driver software, and which are mapped at the operating system to a <acronym title="Virtual Key">VK</acronym> ("virtual key"), which in turn may be mapped to the user-defined key configuration. Key values are a high-level abstraction of that final mapping.</p>
<h5><a id="keyboard-desktop" href="#keyboard-desktop">6.1.2.1 Desktop and Laptop Keyboards</a></h5>
<p>In the case where an author wishes to rely on the mechanical layout of a desktop or laptop keyboard, this specification suggests the keyboard configuration specified in ISO/IEC 9995, parts 2 and 3 [<cite><a class="informative" href="#references-ISO-9995-2-3">ISO-9995-2/3</a></cite>], which defines a common layout for primary, secondary, and auxiliary key mappings on a typical alphanumeric keyboard, as a common layout appropriate to some international uses.</p>
- <p class="note" id=""><strong>Note:</strong> This keyboard layout is still, in essence, a <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard, and will not match the keyboards or configurations of many users. Authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
+ <p class="note" id="_51"><strong>Note:</strong> This keyboard layout is still, in essence, a <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard, and will not match the keyboards or configurations of many users. Authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
<div class="figure" style="text-align: center">
<object type="image/svg+xml" data="images/ISOIEC-9995-3-FCD-2009A.svg" width="900" height="300">
<img src="images/ISOIEC-9995-3-FCD-2009A.png" alt="A graphical depiction of an ISO standard defining layouts of computer keyboards, ISO/IEC 9995, parts 2 and 3" />
@@ -4383,7 +4925,7 @@
<h5><a id="keyboard-mobile" href="#keyboard-mobile">6.1.2.2 Mobile Keypads</a></h5>
<p>In the case where an author wishes to rely on the mechanical layout of a mobile keypad, this specification suggests the keyboard configuration specified in ISO/IEC 9995-8:2006 [<cite><a class="informative" href="#references-ISO-9995-8">ISO-9995-8</a></cite>], which defines a numeric keypad layout and secondary assignment of Unicode characters in the range <abbr title="a-z">\u0061..\u007A</abbr> to the number keys <code>2</code> through <code>9</code>, as a common layout appropriate to some international uses.</p>
- <p class="note" id=""><strong>Note:</strong> This keypad layout, and in particular the distribution of letters is for Western devices, and will not match the keypads or configurations of many users. Authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
+ <p class="note" id="_52"><strong>Note:</strong> This keypad layout, and in particular the distribution of letters is for Western devices, and will not match the keypads or configurations of many users. Authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
<div class="figure" style="text-align: center">
<object type="image/svg+xml" data="images/ISOIEC-9995-8-2006.svg" width="180" height="240">
<img src="images/ISOIEC-9995-8-2006.png" alt="A graphical depiction of an ISO standard defining layouts of numeric keypads, with distribution of letters on the keys, ISO/IEC 9995-8:2006" />
@@ -4401,7 +4943,7 @@
<p>Key values can be used to detect the value of a key which has been pressed, using the <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute. Authors can retrieve the <a class="def" href="#glossary-character-value">character value</a> of upper- or lower-case letters, number, symbols, or other character-producing keys, and also the <a class="def" href="#glossary-key-name">key name</a> of control keys, modifier keys, function keys, or other keys that do not generate characters; these values can be used for monitoring particular input strings, for detecting and acting on modifier key input in combination with other inputs (such as a mouse), for creating virtual keyboards, or for any number of other purposes.</p>
<p>Key values can also be used by authors in string comparisons, as values for markup attributes (such as the HTML <code>accesskey</code>) in conforming <a class="def" href="#glossary-host-language">host languages</a>, or for other related purposes. A conforming <a class="def" href="#glossary-host-language">host language</a> should allow authors to use either of the two equivalent string values for a key value: the <a class="def" href="#glossary-character-value">character value</a>, or the <a class="def" href="#glossary-key-name">key name</a>.</p>
<p class="issue"><strong>Issue:</strong> mention that author should use case-insensitive matching to capture both "t" and "T" for hotkeys, etc.?</p>
- <p class="note" id=""><strong>Note:</strong> While implementations are recommended to use the most relevant value for a key independently of the platform or keyboard layout mappings, authors should not make assumption on the ability of keyboard devices to generate them. When using keyboard events and key values for shortcut-key combinations, authors should <q>consider using numbers and function keys (F4, F5, and so on) instead of letters</q> ([<cite><a class="informative" href="#references-DWW95">DWW95</a></cite>]) given that most keyboard layouts will provide keys for those.</p>
+ <p class="note" id="_53"><strong>Note:</strong> While implementations are recommended to use the most relevant value for a key independently of the platform or keyboard layout mappings, authors should not make assumption on the ability of keyboard devices to generate them. When using keyboard events and key values for shortcut-key combinations, authors should <q>consider using numbers and function keys (F4, F5, and so on) instead of letters</q> ([<cite><a class="informative" href="#references-DWW95">DWW95</a></cite>]) given that most keyboard layouts will provide keys for those.</p>
<!-- , and where the key used should default to the most appropriate key for the function, language, operating system, device, and other environmental factors (such as <code>ctrl+c</code> for copy operations) -->
<p>It is important to note that a key value does not indicate a specific key on the physical keyboard, nor does it reflect the character printed on the key; a key value indicates the current value of the event with consideration to the current state of all active keys and key input modes (including shift modes and <a class="def" href="#glossary-dead-key">dead keys</a>), as reflected in the operating-system mapping of the keyboard and reported to the implementation. In other words, the key value for the key marked <code>'O'</code> on a <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard has the key value <code>'o'</code> in an unshifted state, <code>'O'</code> in a shifted state, <code>'ö'</code> in an unshifted state during a dead-key operation to add an umlaut diacritic, and <code>'Ö'</code> in a shifted state during a dead-key operation to add an umlaut diacritic. Because a user may map their keyboard to an arbitrary custom configuration, the author should not assume that a relationship exists between the shifted and unshifted states of a key and the majuscule form (uppercase or capital letters) and minuscule form (lowercase or small letters) of a character representation, but should instead use the value of the <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute. The keyboard depicted in Figure 3 illustrates one possible set of key mappings on one possible keyboard layout; many others exist, both standard and idiosyncratic.</p>
<p>It is also important to note that there is not a one-to-one relationship between key event states and key values. A particular key value may be associated with multiple keys; for example, many standard keyboards contain more than one key with the <code class="value">'Shift'</code> key value (normally distinguished by the <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> values <a href="#events-DOM_KEY_LOCATION_LEFT"><code class="constant-name">DOM_KEY_LOCATION_LEFT</code></a> and <a href="#events-DOM_KEY_LOCATION_RIGHT"><code class="constant-name">DOM_KEY_LOCATION_RIGHT</code></a>) or <code class="value">'8'</code> key value (normally distinguished by the <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> values <a href="#events-DOM_KEY_LOCATION_STANDARD"><code class="constant-name">DOM_KEY_LOCATION_STANDARD</code></a> and <a href="#events-DOM_KEY_LOCATION_NUMPAD"><code class="constant-name">DOM_KEY_LOCATION_NUMPAD</code></a>), and user-configured custom keyboard layouts may duplicate any key value in multiple key-state scenarios (note that <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> is intended for standard keyboard layouts, and cannot always indicate a meaningful distinction).</p>
@@ -4537,7 +5079,7 @@
<p>This specification includes a model for <a class="def" href="#glossary-ime">input method editors (IMEs)</a>, through the <a href="#events-compositionevents">CompositionEvent</a> interface and events. However, composition events and keyboard events do not necessarily map as a one-to-one relationship. As an example, receiving a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> for the "Accept" key value does not necessarily imply that the text currently selected in the <a class="def" href="#glossary-ime">IME</a> is being accepted, but indicates only that a keystroke happened, disconnected from the <a class="def" href="#glossary-ime">IME</a> Accept functionality (which would normally result in a <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event in most <a class="def" href="#glossary-ime">IME</a> systems). Keyboard events cannot be used to determine the current state of the input method editor, which should be obtained through the <a href="#events-Events-CompositionEvent-data"><code>data</code></a> attribute of the <a href="#events-compositionevents">CompositionEvent</a> interface. Additionally, <a class="def" href="#glossary-ime">IME</a> systems and devices vary in their functionality, and in which keys are used for activating that functionality, such that the <code class="value">'Convert'</code> and <code class="value">'Accept'</code> keys may be represented by other available keys.</p>
<p>Keyboard events correspond to the events generated by the input device after the keyboard layout mapping but before the processing of the input method editor.</p>
- <p>The following example describes a possible sequence of keys to generate the Unicode character 市 (Kanji character, part of CJK Unified Ideographs) using Japanese input methods. This example assumes that the input method editor is activated and in the Japanese-Romaji input mode. The keys <code class="value">'Convert'</code> and <code class="value">'Accept'</code> may be replaced by others depending on the input device in use and the configuration of the IME, e.g. it could be respectively <code class="value">'\u0020'</code> (Space key) and <code class="value">'Enter'</code>. <span class="note" id=""><strong>Note:</strong><code class="value">'詩'</code> ("poem") and <code class="value">'市'</code> ("city") are homophones, both pronounced "shi", so the user must use the <code class="value">'Convert'</code> key to select the proper option.</span></p>
+ <p>The following example describes a possible sequence of keys to generate the Unicode character 市 (Kanji character, part of CJK Unified Ideographs) using Japanese input methods. This example assumes that the input method editor is activated and in the Japanese-Romaji input mode. The keys <code class="value">'Convert'</code> and <code class="value">'Accept'</code> may be replaced by others depending on the input device in use and the configuration of the IME, e.g. it could be respectively <code class="value">'\u0020'</code> (Space key) and <code class="value">'Enter'</code>. <span class="note" id="_54"><strong>Note:</strong><code class="value">'詩'</code> ("poem") and <code class="value">'市'</code> ("city") are homophones, both pronounced "shi", so the user must use the <code class="value">'Convert'</code> key to select the proper option.</span></p>
<div class="example" id="example-compo">
<p><strong>Example:</strong></p>
<ol>
@@ -4649,7 +5191,7 @@
<div>
<h4><a id="keyset-Guide" href="#keyset-Guide">6.2.6 Guidelines for selecting and defining key values</a></h4>
- <p class="note" id=""><strong>Note:</strong> This section is normative.</p>
+ <p class="note" id="_55"><strong>Note:</strong> This section is normative.</p>
<p>The list of key values contained in this specification is not exhaustive and input devices may have to define their own key values. Here is a algorithm to determine which key value to use:</p>
<ol>
<li>Consider the current function of the key (i.e., with modifiers), taking into consideration the keyboard layout mapping in use, to determine if the key is represented by the set of defined key values, if a corresponding Unicode character exists from which a key value may be derived, or if a new key value must be defined.
@@ -4686,7 +5228,7 @@
<p>This section defines a list of key values which implementations must support, at a minimum; implementations may support additional key values, in a manner conforming to the <a href="#keyset-Guide">guidelines for selecting and defining key values</a>. Each key value defines one or both of the following: a <a class="def" href="#glossary-character-value">character value</a> and a <a class="def" href="#glossary-key-name">key name</a>. The <a href="#events-Events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute of an event must always be the most author-friendly of these available, in the following order: <a class="def codepoint" href="#glossary-character-value">character value</a>, or <a class="def keyname" href="#glossary-key-name">key name</a>. Future versions of this specification may include key values not included here, which have become common since the publication of this specification.</p>
<p>The <a class="def" href="#glossary-key-name">key names</a> defined in this specification are based on the sets of keycodes from the <code>java.awt.event.KeyEvent</code> interface of the Java Platform, Standard Edition 6 API Specification [<cite><a class="informative" href="#references-KeyEvent">KeyEvent for Java</a></cite>], and the <code>System.Windows.Forms.Keys</code> key enumeration of the Microsoft .NET Framework 4.0 Class Library [<cite><a class="informative" href="#references-Keys">Keys enumeration for .Net</a></cite>]. The <a class="def" href="#glossary-character-value">character values</a> defined in this specification are derived from the Unicode standard [<a href="#references-Unicode">Unicode</a>].</p>
- <p class="note" id=""><strong>Note:</strong> The key names <code class="value">'NumPad0'</code>, <code class="value">'NumPad1'</code>, <code class="value">'NumPad2'</code>, <code class="value">'NumPad3'</code>, <code class="value">'NumPad4'</code>, <code class="value">'NumPad5'</code>, <code class="value">'NumPad6'</code>, <code class="value">'NumPad7'</code>, <code class="value">'NumPad8'</code>, and <code class="value">'NumPad9'</code>, found in some keyboard enumeration sets, are not distinguished from other numerical key values in this set; an author may use the <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> attribute to discover if a key originated from the numeric keypad.</p>
+ <p class="note" id="_56"><strong>Note:</strong> The key names <code class="value">'NumPad0'</code>, <code class="value">'NumPad1'</code>, <code class="value">'NumPad2'</code>, <code class="value">'NumPad3'</code>, <code class="value">'NumPad4'</code>, <code class="value">'NumPad5'</code>, <code class="value">'NumPad6'</code>, <code class="value">'NumPad7'</code>, <code class="value">'NumPad8'</code>, and <code class="value">'NumPad9'</code>, found in some keyboard enumeration sets, are not distinguished from other numerical key values in this set; an author may use the <a href="#events-Events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> attribute to discover if a key originated from the numeric keypad.</p>
<!-- <p>Javascript escaped characters may have issues because they are based on UTF-16 encoding, in that it uses surrogate pairs for values outside the Basic Multilingual Plane.</p> -->
<div id="js-escape" class="issue">
<p><strong>Issue:</strong> Javascript escaped characters may have issues:</p>
@@ -4696,7 +5238,7 @@
<li>expressing characters using surrogate pairs makes it difficult for a human to look up the value, and requires unnecessary overhead for machine processing; can also cause problems with software written in the incorrect belief that Unicode is a 16-bit character set</li>
<li>problematic for characters on supplementary planes (emoji, or Chinese characters on plane 2), some of which are keyable</li>
<li>CharMod conformance [<cite><a class="normative" href="#references-charmod">CharMod</a></cite>] <a href="http://www.w3.org/TR/charmod/#C045">expects</a> the use of code points rather than surrogate pairs in escapes</li>
- <li>Javascript escaped characters use surrogate pairs for characters outside the Basic Multilingual Plane ("\uD84E\uDDC2" for 𣧂), rather than C-style fixed-length characters ("\U000239c2" for 𣧂) or delimited escapes such as Numeric Character References ("&#x239C2;"). <span class="note" id=""><strong>Note:</strong> 𣧂 is a Chinese character meaning "untidy".</span></li>
+ <li>Javascript escaped characters use surrogate pairs for characters outside the Basic Multilingual Plane ("\uD84E\uDDC2" for 𣧂), rather than C-style fixed-length characters ("\U000239c2" for 𣧂) or delimited escapes such as Numeric Character References ("&#x239C2;"). <span class="note" id="_57"><strong>Note:</strong> 𣧂 is a Chinese character meaning "untidy".</span></li>
</ul>
</div>
<dl id="key-value-set">
@@ -4801,7 +5343,7 @@
<dt><a id="key-Enter"><code class="value keyname">'Enter'</code></a></dt>
<dd>The Enter key.
- <span class="note" id=""><strong>Note:</strong> This key value shall be also used for the Return (Macintosh numpad) key.</span>
+ <span class="note" id="_58"><strong>Note:</strong> This key value must also be used for the <code>Return</code> (Macintosh numpad) key.</span>
</dd>
<dt><a id="key-EraseEof"><code class="value keyname">'EraseEof'</code></a></dt>
@@ -4956,7 +5498,7 @@
<dt><a id="key-Meta"><code class="value keyname">'Meta'</code></a></dt>
<dd>The Meta key.
- <span class="note" id=""><strong>Note:</strong> This key value shall be also used for the Return (Macintosh numpad) key.</span>
+ <span class="note" id="_59"><strong>Note:</strong> This key value shall be also used for the Apple <code>Command</code> key.</span>
</dd>
<dt><a id="key-MediaNextTrack"><code class="value keyname">'MediaNextTrack'</code></a></dt>
@@ -5000,7 +5542,7 @@
<dt><a id="key-Power"><code class="value keyname">'Power'</code></a></dt>
<dd>The Power key.
- <span class="note" id=""><strong>Note:</strong> Some devices may not expose this key to the operating environment.</span>
+ <span class="note" id="_61"><strong>Note:</strong> Some devices may not expose this key to the operating environment.</span>
</dd>
<dt><a id="key-PreviousCandidate"><code class="value keyname">'PreviousCandidate'</code></a></dt>
@@ -5084,7 +5626,7 @@
<dt><a id="key-U-0008"><code class="value codepoint">'\u0008'</code></a></dt>
<dt><a id="key-Backspace"><code class="value keyname">'Backspace'</code></a></dt>
<dd>The Backspace (Back) key.
- <span class="note" id=""><strong>Note:</strong> This key value shall be also used for the key labeled <code class="value">'delete'</code> MacOS keyboards when not modified by the <code class="value">'Fn'</code> key.</span>
+ <span class="note" id="_62"><strong>Note:</strong> This key value shall be also used for the key labeled <code class="value">'delete'</code> MacOS keyboards when not modified by the <code class="value">'Fn'</code> key.</span>
</dd>
<dt><a id="key-U-0009"><code class="value codepoint">'\u0009'</code></a></dt>
@@ -5490,7 +6032,7 @@
<dt><a id="key-U-007F"><code class="value codepoint">'\u007F'</code></a></dt>
<dt><a id="key-Del"><code class="value keyname">'Del'</code></a></dt>
<dd>The Delete (Del) Key.
- <span class="note" id=""><strong>Note:</strong> This key value shall be also used for the key labeled <code class="value">'delete'</code> MacOS keyboards when modified by the <code class="value">'Fn'</code> key.</span>
+ <span class="note" id="_63"><strong>Note:</strong> This key value shall be also used for the key labeled <code class="value">'delete'</code> MacOS keyboards when modified by the <code class="value">'Fn'</code> key.</span>
</dd>
<dt><a id="key-U-0300"><code class="value codepoint">'\u0300'</code></a></dt>
@@ -5558,7 +6100,7 @@
<dd>The Combining Katakana-Hiragana Semi-Voiced Sound Mark (Dead Semivoiced Sound) key.</dd>
<dt><a id="key-Unidentified"><code class="value keyname">'Unidentified'</code></a></dt>
- <dd>This key value is used when an implementations is unable to identify another key value, due to either hardware, platform, or software constraints. <span class="warning" id=""><strong>Warning!</strong> Conforming implementation must only use this key value when there is no way for the implementation to detect the key value, and does not indicate a conforming implementation by itself.</span></dd>
+ <dd>This key value is used when an implementations is unable to identify another key value, due to either hardware, platform, or software constraints. <span class="warning" id="_64"><strong>Warning!</strong> Conforming implementation must only use this key value when there is no way for the implementation to detect the key value, and does not indicate a conforming implementation by itself.</span></dd>
</dl>
</div>
@@ -5566,7 +6108,7 @@
<div>
<h4><a id="keyset-keyCode-charCode" href="#keyset-keyCode-charCode">6.2.8 Key values, keyCode, and charCode</a></h4>
- <p class="note" id=""><strong>Note:</strong> This section is non-normative.</p>
+ <p class="note" id="_41"><strong>Note:</strong> This section is non-normative.</p>
<p>Browser support for keyboards has traditionally relied on two ad-hoc attributes, <code class="attr-name">keyCode</code>, and <code class="attr-name">charCode</code>. The values for these attributes, and the availability of the attribute, is inconsistent across platforms, keyboard languages and layouts, <a class="def" href="#glossary-user-agent">user agents</a>, versions, and even event types. A significant amount of legacy content, including script libraries, relies upon detecting the <a class="def" href="#glossary-user-agent">user agent</a> and acting accordingly, and any changes to <code class="attr-name">keyCode</code>, or <code class="attr-name">charCode</code> risk breaking as much content as they fix or enable. Additionally, these attributes are not suitable for international usage, or accessibility concerns. Therefore, this specification does not normatively define the <code class="attr-name">keyCode</code>, and <code class="attr-name">charCode</code> attributes, relying instead only on the more robust key values, which can be used safely and consistently in any <a class="def" href="#glossary-user-agent">user agent</a> which conforms to this specification. However, for the purpose of documenting the current state of these attributes and their relation to equivalent key values, this specification contains the following table, which is to be used as an informative reference only, and does not document the full range of values for <code class="attr-name">keyCode</code>, and <code class="attr-name">charCode</code>.</p>