[html5] r7667 - [e] (0) Clean up how we define event handlers that are shadowed for Window on <b [...]
whatwg at whatwg.org
whatwg at whatwg.org
Tue Jan 29 11:18:46 PST 2013
Author: ianh
Date: 2013-01-29 11:18:46 -0800 (Tue, 29 Jan 2013)
New Revision: 7667
Modified:
source
Log:
[e] (0) Clean up how we define event handlers that are shadowed for Window on <body>.
Affected topics: DOM APIs, HTML
Modified: source
===================================================================
--- source 2013-01-29 01:21:13 UTC (rev 7666)
+++ source 2013-01-29 19:18:46 UTC (rev 7667)
@@ -9464,8 +9464,7 @@
// special <span>event handler IDL attributes</span> that only apply to Document objects
[LenientThis] attribute <span>EventHandler</span> <span title="handler-onreadystatechange">onreadystatechange</span>;
};
-<span>Document</span> implements <span>GlobalEventHandlers</span>;
-<span>Document</span> implements <span>NodeEventHandlers</span>;</pre>
+<span>Document</span> implements <span>GlobalEventHandlers</span>;</pre>
<!--ADD-TOPIC:Security-->
@@ -10587,7 +10586,6 @@
[PutForwards=<span title="dom-CSSStyleDeclaration-cssText">cssText</span>] readonly attribute <span>CSSStyleDeclaration</span> <span title="dom-style">style</span>;
};
<span>HTMLElement</span> implements <span>GlobalEventHandlers</span>;
-<span>HTMLElement</span> implements <span>NodeEventHandlers</span>;
interface <dfn>HTMLUnknownElement</dfn> : <span>HTMLElement</span> { };</pre>
@@ -17771,13 +17769,9 @@
<dd><code title="handler-window-onafterprint">onafterprint</code></dd>
<dd><code title="handler-window-onbeforeprint">onbeforeprint</code></dd>
<dd><code title="handler-window-onbeforeunload">onbeforeunload</code></dd>
- <dd><code title="handler-window-onblur">onblur</code></dd>
- <dd><code title="handler-window-onerror">onerror</code></dd>
- <dd><code title="handler-window-onfocus">onfocus</code></dd>
<dd><code title="handler-window-onfullscreenchange">onfullscreenchange</code></dd>
<dd><code title="handler-window-onfullscreenerror">onfullscreenerror</code></dd>
<dd><code title="handler-window-onhashchange">onhashchange</code></dd>
- <dd><code title="handler-window-onload">onload</code></dd>
<dd><code title="handler-window-onmessage">onmessage</code></dd>
<dd><code title="handler-window-onoffline">onoffline</code></dd>
<dd><code title="handler-window-ononline">ononline</code></dd>
@@ -17785,7 +17779,6 @@
<dd><code title="handler-window-onpageshow">onpageshow</code></dd>
<dd><code title="handler-window-onpopstate">onpopstate</code></dd>
<dd><code title="handler-window-onresize">onresize</code></dd>
- <dd><code title="handler-window-onscroll">onscroll</code></dd>
<dd><code title="handler-window-onstorage">onstorage</code></dd>
<dd><code title="handler-window-onunload">onunload</code></dd>
<dt><span title="element-dfn-dom">DOM interface</span>:</dt><!--TOPIC:DOM APIs-->
@@ -17819,15 +17812,12 @@
handlers</span> of the <code>Window</code> object. It also mirrors
their <span>event handler IDL attributes</span>.</p>
- <p>The <code title="handler-window-onblur">onblur</code>, <code
- title="handler-window-onerror">onerror</code>, <code
- title="handler-window-onfocus">onfocus</code>, <code title="handler-window-onload">onload</code>,
- and <code title="handler-window-onscroll">onscroll</code> <span>event handlers</span> of the
- <code>Window</code> object, exposed on the <code>body</code> element, shadow the generic
- <span>event handlers</span> with the same names normally supported by <span>HTML elements</span>.
- With the exception of <code title="handler-window-onerror">onerror</code>, this is actually
- implemented by just using the properties of the <code>HTMLElement</code> interface. The <code
- title="handler-window-onerror">onerror</code> attribute has a different type.</p>
+ <p>The <code title="handler-onblur">onblur</code>, <code
+ title="handler-onerror">onerror</code>, <code
+ title="handler-onfocus">onfocus</code>, <code title="handler-onload">onload</code>,
+ and <code title="handler-onscroll">onscroll</code> <span>event handlers</span> of the
+ <code>Window</code> object, exposed on the <code>body</code> element, replace the generic
+ <span>event handlers</span> with the same names normally supported by <span>HTML elements</span>.</p>
<p class="example">Thus, for example, a bubbling <code
title="event-error">error</code> event dispatched on a child of
@@ -17835,7 +17825,7 @@
trigger the <code title="handler-onerror">onerror</code> <span>event
handler content attributes</span> of that element, then that of the
root <code>html</code> element, and only <em>then</em> would it
- trigger the <code title="handler-window-onerror">onerror</code>
+ trigger the <code title="handler-onerror">onerror</code>
<span title="event handler content attributes">event handler content
attribute</span> on the <code>body</code> element. This is because
the event would bubble from the target, to the <code>body</code>, to
@@ -77722,8 +77712,7 @@
void <span title="dom-window-postMessage">postMessage</span>(any message, DOMString targetOrigin, optional sequence<<span>Transferable</span>> transfer);
};
<span>Window</span> implements <span>GlobalEventHandlers</span>;
-<span>Window</span> implements <span>WindowEventHandlers</span>;
-<span>Window</span> implements <span>ShadowingWindowEventHandlers</span>;</pre>
+<span>Window</span> implements <span>WindowEventHandlers</span>;</pre>
<!-- for more features to add here, look here:
http://msdn.microsoft.com/workshop/author/dhtml/reference/objects/obj_window.asp
@@ -86103,13 +86092,13 @@
<tr><td><dfn title="handler-window-onafterprint"><code>onafterprint</code></dfn> <td> <code title="event-afterprint">afterprint</code>
<tr><td><dfn title="handler-window-onbeforeprint"><code>onbeforeprint</code></dfn> <td> <code title="event-beforeprint">beforeprint</code>
<tr><td><dfn title="handler-window-onbeforeunload"><code>onbeforeunload</code></dfn> <td> <code title="event-beforeunload">beforeunload</code>
- <tr><td><dfn title="handler-window-onblur"><code>onblur</code></dfn> <td> <code title="event-blur">blur</code>
- <tr><td><dfn title="handler-window-onerror"><code>onerror</code></dfn> <td> <code title="event-error">error</code>
- <tr><td><dfn title="handler-window-onfocus"><code>onfocus</code></dfn> <td> <code title="event-focus">focus</code>
+ <tr><td><dfn title="handler-onblur"><code>onblur</code></dfn> <td> <code title="event-blur">blur</code>
+ <tr><td><dfn title="handler-onerror"><code>onerror</code></dfn> <td> <code title="event-error">error</code>
+ <tr><td><dfn title="handler-onfocus"><code>onfocus</code></dfn> <td> <code title="event-focus">focus</code>
<tr><td><dfn title="handler-window-onfullscreenchange"><code>onfullscreenchange</code></dfn> <td> <code title="event-fullscreenchange">fullscreenchange</code>
<tr><td><dfn title="handler-window-onfullscreenerror"><code>onfullscreenerror</code></dfn> <td> <code title="event-fullscreenerror">fullscreenerror</code>
<tr><td><dfn title="handler-window-onhashchange"><code>onhashchange</code></dfn> <td> <code title="event-hashchange">hashchange</code> <!-- new -->
- <tr><td><dfn title="handler-window-onload"><code>onload</code></dfn> <td> <code title="event-load">load</code> <!-- widely used -->
+ <tr><td><dfn title="handler-onload"><code>onload</code></dfn> <td> <code title="event-load">load</code> <!-- widely used -->
<tr><td><dfn title="handler-window-onmessage"><code>onmessage</code></dfn> <td> <code title="event-message">message</code> <!-- new for postMessage -->
<tr><td><dfn title="handler-window-onoffline"><code>onoffline</code></dfn> <td> <code title="event-offline">offline</code> <!-- new -->
<tr><td><dfn title="handler-window-ononline"><code>ononline</code></dfn> <td> <code title="event-online">online</code> <!-- new -->
@@ -86117,7 +86106,7 @@
<tr><td><dfn title="handler-window-onpageshow"><code>onpageshow</code></dfn> <td> <code title="event-pageshow">pageshow</code> <!-- new -->
<tr><td><dfn title="handler-window-onpopstate"><code>onpopstate</code></dfn> <td> <code title="event-popstate">popstate</code> <!-- new -->
<tr><td><dfn title="handler-window-onresize"><code>onresize</code></dfn> <td> <code title="event-resize">resize</code> <!-- widely used --> <!-- [CSSOM] -->
- <tr><td><dfn title="handler-window-onscroll"><code>onscroll</code></dfn> <td> <code title="event-scroll">scroll</code>
+ <tr><td><dfn title="handler-onscroll"><code>onscroll</code></dfn> <td> <code title="event-scroll">scroll</code>
<tr><td><dfn title="handler-window-onstorage"><code>onstorage</code></dfn> <td> <code title="event-storage">storage</code> <!-- new -->
<tr><td><dfn title="handler-window-onunload"><code>onunload</code></dfn> <td> <code title="event-unload">unload</code> <!-- widely used -->
</table>
@@ -86156,6 +86145,9 @@
<pre class="idl">[NoInterfaceObject]
interface <dfn>GlobalEventHandlers</dfn> {
attribute <span>EventHandler</span> <span title="handler-onabort">onabort</span>;
+ attribute <span>EventHandler</span> <span title="handler-onblur">onblur</span>;
+ attribute <span>OnErrorEventHandler</span> <span title="handler-onerror">onerror</span>;
+ attribute <span>EventHandler</span> <span title="handler-onfocus">onfocus</span>;
attribute <span>EventHandler</span> <span title="handler-oncancel">oncancel</span>;
attribute <span>EventHandler</span> <span title="handler-oncanplay">oncanplay</span>;
attribute <span>EventHandler</span> <span title="handler-oncanplaythrough">oncanplaythrough</span>;
@@ -86180,6 +86172,7 @@
attribute <span>EventHandler</span> <span title="handler-onkeydown">onkeydown</span>;
attribute <span>EventHandler</span> <span title="handler-onkeypress">onkeypress</span>;
attribute <span>EventHandler</span> <span title="handler-onkeyup">onkeyup</span>;
+ attribute <span>EventHandler</span> <span title="handler-onload">onload</span>;
attribute <span>EventHandler</span> <span title="handler-onloadeddata">onloadeddata</span>;
attribute <span>EventHandler</span> <span title="handler-onloadedmetadata">onloadedmetadata</span>;
attribute <span>EventHandler</span> <span title="handler-onloadstart">onloadstart</span>;
@@ -86195,6 +86188,7 @@
attribute <span>EventHandler</span> <span title="handler-onprogress">onprogress</span>;
attribute <span>EventHandler</span> <span title="handler-onratechange">onratechange</span>;
attribute <span>EventHandler</span> <span title="handler-onreset">onreset</span>;
+ attribute <span>EventHandler</span> <span title="handler-onscroll">onscroll</span>;
attribute <span>EventHandler</span> <span title="handler-onseeked">onseeked</span>;
attribute <span>EventHandler</span> <span title="handler-onseeking">onseeking</span>;
attribute <span>EventHandler</span> <span title="handler-onselect">onselect</span>;
@@ -86209,15 +86203,6 @@
};
[NoInterfaceObject]
-interface <dfn>NodeEventHandlers</dfn> {
- attribute <span>EventHandler</span> <span title="handler-onblur">onblur</span>;
- attribute <span>OnErrorEventHandler</span> <span title="handler-onerror">onerror</span>;
- attribute <span>EventHandler</span> <span title="handler-onfocus">onfocus</span>;
- attribute <span>EventHandler</span> <span title="handler-onload">onload</span>;
- attribute <span>EventHandler</span> <span title="handler-onscroll">onscroll</span>;
-};
-
-[NoInterfaceObject]
interface <dfn>WindowEventHandlers</dfn> {
attribute <span>EventHandler</span> <span title="handler-window-onafterprint">onafterprint</span>;
attribute <span>EventHandler</span> <span title="handler-window-onbeforeprint">onbeforeprint</span>;
@@ -86235,15 +86220,6 @@
attribute <span>EventHandler</span> <span title="handler-window-onresize">onresize</span>;
attribute <span>EventHandler</span> <span title="handler-window-onstorage">onstorage</span>;
attribute <span>EventHandler</span> <span title="handler-window-onunload">onunload</span>;
-};
-
-[NoInterfaceObject]
-interface <dfn>ShadowingWindowEventHandlers</dfn> {
- attribute <span>EventHandler</span> <span title="handler-window-onblur">onblur</span>;
-// attribute <span>OnErrorEventHandler</span> <span title="handler-window-onerror">onerror</span>;
- attribute <span>EventHandler</span> <span title="handler-window-onfocus">onfocus</span>;
- attribute <span>EventHandler</span> <span title="handler-window-onload">onload</span>;
- attribute <span>EventHandler</span> <span title="handler-window-onscroll">onscroll</span>;
};</pre>
@@ -115249,13 +115225,9 @@
<li><code title="handler-window-onafterprint">onafterprint</code></li>
<li><code title="handler-window-onbeforeprint">onbeforeprint</code></li>
<li><code title="handler-window-onbeforeunload">onbeforeunload</code></li>
- <li><code title="handler-window-onblur">onblur</code></li>
- <li><code title="handler-window-onerror">onerror</code></li>
- <li><code title="handler-window-onfocus">onfocus</code></li>
<li><code title="handler-window-onfullscreenchange">onfullscreenchange</code></li>
<li><code title="handler-window-onfullscreenerror">onfullscreenerror</code></li>
<li><code title="handler-window-onhashchange">onhashchange</code></li>
- <li><code title="handler-window-onload">onload</code></li>
<li><code title="handler-window-onmessage">onmessage</code></li>
<li><code title="handler-window-onoffline">onoffline</code></li>
<li><code title="handler-window-ononline">ononline</code></li>
@@ -115263,7 +115235,6 @@
<li><code title="handler-window-onpageshow">onpageshow</code></li>
<li><code title="handler-window-onpopstate">onpopstate</code></li>
<li><code title="handler-window-onresize">onresize</code></li>
- <li><code title="handler-window-onscroll">onscroll</code></li>
<li><code title="handler-window-onstorage">onstorage</code></li>
<li><code title="handler-window-onunload">onunload</code></li>
</ul>
@@ -115271,15 +115242,12 @@
<p>The DOM interface also exposes <span>event handler IDL attributes</span> that mirror those on
the <code>Window</code> element.</p>
- <p>The <code title="handler-window-onblur">onblur</code>, <code
- title="handler-window-onerror">onerror</code>, <code
- title="handler-window-onfocus">onfocus</code>, <code title="handler-window-onload">onload</code>,
- and <code title="handler-window-onscroll">onscroll</code> <span>event handlers</span> of the
- <code>Window</code> object, exposed on the <code>frameset</code> element, shadow the generic
- <span>event handlers</span> with the same names normally supported by <span>HTML elements</span>.
- With the exception of <code title="handler-window-onerror">onerror</code>, this is actually
- implemented by just using the properties of the <code>HTMLElement</code> interface. The <code
- title="handler-window-onerror">onerror</code> attribute has a different type.</p>
+ <p>The <code title="handler-onblur">onblur</code>, <code
+ title="handler-onerror">onerror</code>, <code
+ title="handler-onfocus">onfocus</code>, <code title="handler-onload">onload</code>,
+ and <code title="handler-onscroll">onscroll</code> <span>event handlers</span> of the
+ <code>Window</code> object, exposed on the <code>frameset</code> element, replace the generic
+ <span>event handlers</span> with the same names normally supported by <span>HTML elements</span>.</p>
<hr>
@@ -117322,13 +117290,9 @@
<code title="handler-window-onafterprint">onafterprint</code>;
<code title="handler-window-onbeforeprint">onbeforeprint</code>;
<code title="handler-window-onbeforeunload">onbeforeunload</code>;
- <code title="handler-window-onblur">onblur</code>;
- <code title="handler-window-onerror">onerror</code>;
- <code title="handler-window-onfocus">onfocus</code>;
<code title="handler-window-onfullscreenchange">onfullscreenchange</code>;
<code title="handler-window-onfullscreenerror">onfullscreenerror</code>;
<code title="handler-window-onhashchange">onhashchange</code>;
- <code title="handler-window-onload">onload</code>;
<code title="handler-window-onmessage">onmessage</code>;
<code title="handler-window-onoffline">onoffline</code>;
<code title="handler-window-ononline">ononline</code>;
@@ -117336,7 +117300,6 @@
<code title="handler-window-onpageshow">onpageshow</code>;
<code title="handler-window-onpopstate">onpopstate</code>;
<code title="handler-window-onresize">onresize</code>;
- <code title="handler-window-onscroll">onscroll</code>;
<code title="handler-window-onstorage">onstorage</code>;
<code title="handler-window-onunload">onunload</code></td>
<td><code>HTMLBodyElement</code></td>
@@ -119983,12 +119946,6 @@
<td> <span title="event handler content attributes">Event handler content attribute</span>
<tr>
- <th id="ix-handler-window-onblur"> <code title="">onblur</code>
- <td> <code title="handler-window-onblur">body</code>
- <td> <code title="event-blur">blur</code> event handler for <code>Window</code> object
- <td> <span title="event handler content attributes">Event handler content attribute</span>
-
- <tr>
<th id="ix-handler-onblur"> <code title="">onblur</code>
<td> <span title="handler-onblur">HTML elements</span>
<td> <code title="event-blur">blur</code> event handler
@@ -120109,24 +120066,12 @@
<td> <span title="event handler content attributes">Event handler content attribute</span>
<tr>
- <th id="ix-handler-window-onerror"> <code title="">onerror</code>
- <td> <code title="handler-window-onerror">body</code>
- <td> <code title="event-error">error</code> event handler for <code>Window</code> object, and handler for <a href="#runtime-script-errors">script error notifications</a>
- <td> <span title="event handler content attributes">Event handler content attribute</span>
-
- <tr>
<th id="ix-handler-onerror"> <code title="">onerror</code>
<td> <span title="handler-onerror">HTML elements</span>
- <td> <code title="event-error">error</code> event handler
+ <td> <code title="event-error">error</code> event handler, and handler for <a href="#runtime-script-errors">script error notifications</a>
<td> <span title="event handler content attributes">Event handler content attribute</span>
<tr>
- <th id="ix-handler-window-onfocus"> <code title="">onfocus</code>
- <td> <code title="handler-window-onfocus">body</code>
- <td> <code title="event-focus">focus</code> event handler for <code>Window</code> object
- <td> <span title="event handler content attributes">Event handler content attribute</span>
-
- <tr>
<th id="ix-handler-onfocus"> <code title="">onfocus</code>
<td> <span title="handler-onfocus">HTML elements</span>
<td> <code title="event-focus">focus</code> event handler
@@ -120181,12 +120126,6 @@
<td> <span title="event handler content attributes">Event handler content attribute</span>
<tr>
- <th id="ix-handler-window-onload"> <code title="">onload</code>
- <td> <code title="handler-window-onload">body</code>
- <td> <code title="event-load">load</code> event handler for <code>Window</code> object
- <td> <span title="event handler content attributes">Event handler content attribute</span>
-
- <tr>
<th id="ix-handler-onload"> <code title="">onload</code>
<td> <span title="handler-onload">HTML elements</span>
<td> <code title="event-load">load</code> event handler
@@ -120325,12 +120264,6 @@
<td> <span title="event handler content attributes">Event handler content attribute</span>
<tr>
- <th id="ix-handler-window-onscroll"> <code title="">onscroll</code>
- <td> <code title="handler-window-onscroll">body</code>
- <td> <code title="event-scroll">scroll</code> event handler for <code>Window</code> object
- <td> <span title="event handler content attributes">Event handler content attribute</span>
-
- <tr>
<th id="ix-handler-onscroll"> <code title="">onscroll</code>
<td> <span title="handler-onscroll">HTML elements</span>
<td> <code title="event-scroll">scroll</code> event handler
More information about the Commit-Watchers
mailing list