Add comments after each </section>
authorgarykac@google.com
Wed, 13 Nov 2013 16:29:07 +0800
changeset 544 eb5cf0c88b21
parent 543 d8dcb07951b2
child 545 90454480600e
Add comments after each </section>
Update some section names for consistency.
html/DOM3-Events.html
--- a/html/DOM3-Events.html	Wed Nov 13 09:34:08 2013 +0800
+++ b/html/DOM3-Events.html	Wed Nov 13 16:29:07 2013 +0800
@@ -83,7 +83,7 @@
 		<p>This specification defines the Document Object Model Events Level 3, a generic platform- and language-neutral event system which allows registration of event handlers,
 			describes event flow through a tree structure, and provides basic contextual information for each event. The Document Object Model Events Level 3 builds on the
 			Document Object Model Events Level 2 [<a href="#references-DOM2Events">DOM2 Events</a>].</p>
-	</section>
+	</section>  <!-- abstract -->
 
 	<!-- Section: SOTD ========================================================-->
 	<section id="sotd">
@@ -500,7 +500,7 @@
 			<dd>A modifier key changes the normal behavior of a key, such as to produce a character of a different case (as with the <a href="#key-Shift"><code class="key">
 				'Shift'</code></a> key), or to alter what functionality the key triggers (as with the <a href="#key-Fn"><code class="key">'Fn'</code></a> or <a href="#key-Alt">
 				<code class="key">'Alt'</code></a> keys).  Refer to the <a href="#widl-KeyboardEvent-getModifierState"><code>KeyboardEvent.getModifierState()</code></a>
-				method for a list of modifier keys defined in this specification.  See also <a href="#keys-Modifiers">Modifier keys</a>.</dd>
+				method for a list of modifier keys defined in this specification.  See also <a href="#keys-modifiers">Modifier keys</a>.</dd>
 
 			<dt id="glossary-namespaceURI"><dfn>namespace URI</dfn></dt>
 			<dd>A <em>namespace URI</em> is a URI that identifies an XML namespace. This is called the namespace name in [<cite><a class="informative" href="#references-Namespaces10">XML
@@ -637,7 +637,7 @@
 				<div class="example-title"></div>
 				<p>In the following code, the exception thrown from the call to <code>throw "Error"</code> does not propagate into the parent scope
 				(which would prevent the <code>console.log</code> statement from executing):</p>
-				<pre>var e = document.createEvent("Event");
+<pre>var e = document.createEvent("Event");
 e.initEvent("myevent", false, false);
 var target = document.createElement("div");
 target.addEventListener("myevent", function () {
@@ -712,7 +712,7 @@
 
 			<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>
-		</section>
+		</section>  <!-- event-flow -->
 
 		<section id="event-flow-default-cancel">
 			<h2>Default actions and cancelable events</h2>
@@ -769,7 +769,7 @@
 				default action</a> of a <a class="eventtype" href="#event-type-wheel"><code>wheel</code></a> event, while another implementation might instead zoom the document as its <a class="def"
 				href="#glossary-default-action">default action</a>.</p>
 			</div>
-		</section>
+		</section>  <!-- event-flow-default-cancel -->
 
 		<section id="sync-async">
 			<h2>Synchronous and asynchronous events</h2>
@@ -826,8 +826,8 @@
 
 				<p class="note"><strong>Authoring Note:</strong> Certain events, such as <q>hotkeys</q> or control keys pressed in a certain sequence, can be
 					<q>swallowed</q> by the operating system or the application, interrupting the expected <a class="def" href="#glossary-event-order">event order</a>.</p>
-			</section>
-		</section>
+			</section>  <!-- event-order-and-loops -->
+		</section>  <!-- sync-async -->
 
 		<section id="trusted-events">
 			<h2>Trusted events</h2>
@@ -844,7 +844,7 @@
 				untrusted events have an <a href="#widl-Event-isTrusted"><code>isTrusted</code></a> attribute value of <code>false</code>, but still initiate any
 				<a class="def" href="#glossary-default-action">default actions</a> for backwards compatibility. All other untrusted events MUST behave
 				as if the <a href="#widl-Event-preventDefault"><code>Event.preventDefault()</code></a> method had been called on that event.</p>
-		</section>
+		</section>  <!-- trusted-events -->
 
 		<section id="event-flow-activation">
 			<h2>Activation triggers and behavior</h2>
@@ -915,7 +915,7 @@
 
 				<p class="note"><strong>Note:</strong> The activation of an event target is device dependent, but is also application dependent, e.g., a link in a document can be activated
 					using a mouse click or a mouse double click.</p>
-			</section>
+			</section>  <!-- click-synthesis -->
 
 			<section id="events-activation-event-order">
 				<h3>Activation event order</h3>
@@ -961,8 +961,8 @@
 						</td>
 					</tr>
 				</table>
-			</section>
-		</section>
+			</section>  <!-- events-activation-event-order -->
+		</section>  <!-- event-flow-activation -->
 
 		<section id="event-exceptions">
 			<h2>Event exceptions</h2>
@@ -994,7 +994,7 @@
 						interface that the implementation does not support.</td>
 				</tr>
 			</table>
-		</section>
+		</section>  <!-- event-exceptions -->
 	</section>  <!-- dom-event-architecture -->
 
 	<!-- Section 4: Basic Event Interfaces ========================================================-->
@@ -1219,7 +1219,7 @@
 					<p>The <a class="def" href="#glossary-un-initialized-value">un-initialized value</a> of this attribute MUST be <code>false</code>.</p>
 				</dd>
 			</dl>
-		</section><!-- Event -->
+		</section><!-- interface-Event -->
 
 		<section id="interface-CustomEvent">
 			<h2>Interface CustomEvent</h2>
@@ -1246,7 +1246,7 @@
 					<p>The <a class="def" href="#glossary-un-initialized-value">un-initialized value</a> of this attribute MUST be <code>null</code>.</p>
 				</dd>
 			</dl>
-		</section><!-- CustomEvent -->
+		</section><!-- interface-CustomEvent -->
 
 		<section id="interface-EventTarget">
 			<h2>Interface EventTarget</h2>
@@ -1392,7 +1392,7 @@
 						is thrown.</p>
 				</dd>
 			</dl>
-		</section><!-- EventTarget -->
+		</section><!-- interface-EventTarget -->
 
 		<section id="interface-EventListener">
 			<h2>Interface EventListener</h2>
@@ -1429,7 +1429,7 @@
 					</dl>
 				</dd>
 			</dl>
-		</section><!-- EventListener -->
+		</section><!-- interface-EventListener -->
 
 		<section id="interface-DocumentEvent">
 			<h2>Interface DocumentEvent</h2>
@@ -1511,7 +1511,7 @@
 					</dl>
 				</dd>
 			</dl>
-		</section><!-- DocumentEvent -->
+		</section><!-- interface-DocumentEvent -->
 
 	</section>  <!-- event-interfaces  -->
 
@@ -1823,8 +1823,8 @@
 
 				<p class="note"><strong>Note: </strong>The event objects associated with the event types described above contain additional context information--refer to the description of the DOM
 					interfaces for further information.</p>
-			</section>
-		</section>
+			</section>  <!-- event-types-list -->
+		</section>  <!-- event-types -->
 
 		<section id="event-definitions">
 			<h2>Event Module Definitions</h2>
@@ -2329,7 +2329,7 @@
 						</dd>
 
 					</dl>
-				</section>
+				</section>  <!-- interface-FocusEvent -->
 
 				<section id="events-focusevent-event-order">
 					<h4>Focus Event Order</h4>
@@ -2380,7 +2380,7 @@
 
 					<p class="note"><strong>Note:</strong>  This specification does not define the behavior of focus events when interacting with methods such as <code>focus()</code> or
 						<code>blur()</code>. See the relevant specifications where those methods are defined for such behavior.</p>
-				</section>
+				</section>  <!-- events-focusevent-event-order -->
 
 				<section id="events-focusevent-doc-focus">
 					<h4>Document Focus and Focus Context</h4>
@@ -2420,7 +2420,7 @@
 						but not by tabbing to it.  Documents MAY contain multiple focus rings.  Other specifications MAY define a more complex focus model than is described in this specification,
 						including allowing multiple elements to have the current focus.
 						</p>
-				</section>
+				</section>  <!-- events-focusevent-doc-focus -->
 
 				<p>The Focus event types are listed below.</p>
 
@@ -2662,7 +2662,7 @@
 						</dd>
 					</dl>
 				</div>
-			</section>
+			</section>  <!-- events-focusevent -->
 
 			<section id="events-mouseevents">
 				<h3>Mouse Event Types</h3>
@@ -2814,7 +2814,7 @@
 						<dd>
 							<p class="intro-dom">Introduced in DOM Level 3</p>
 
-							<p>Queries the state of a modifier using a key value. See also <a href="#keys-Modifiers">Modifier keys</a>.</p>
+							<p>Queries the state of a modifier using a key value. See also <a href="#keys-modifiers">Modifier keys</a>.</p>
 
 							<p>Returns <code>true</code> if it is a modifier key and the modifier is activated, <code>false</code> otherwise.</p>
 
@@ -2827,7 +2827,7 @@
 						</dd>
 
 					</dl>
-				</section>
+				</section>  <!-- interface-MouseEvent -->
 
 				<p id="current-click-count">Implementations MUST maintain the <em>current click count</em> when generating mouse events. This MUST be a non-negative integer indicating
 					the number of consecutive clicks of a pointing device button within a specific time. The delay after which the count resets is specific to the
@@ -3188,7 +3188,7 @@
 						not be dispatched.</p>
 					</div>
 
-				</section>
+				</section>  <!-- events-mouseevent-event-order -->
 
 				<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>
@@ -4019,7 +4019,7 @@
 						</dd>
 					</dl>
 				</div>
-			</section>
+			</section>  <!-- events-mouseevents -->
 
 			<section id="events-wheelevents">
 				<h3>Wheel Event Types</h3>
@@ -4122,7 +4122,7 @@
 						</dd>
 
 					</dl>
-				</section>
+				</section>  <!-- interface-WheelEvent -->
 
 				<p>The Wheel event types are listed below.</p>
 
@@ -4226,7 +4226,7 @@
 						</dd>
 					</dl>
 				</div>
-			</section>
+			</section>  <!-- events-wheelevents -->
 
 			<section id="events-inputevents">
 				<h3>Input Event Types</h3>
@@ -4248,7 +4248,7 @@
 							<p>The <a class="def" href="#glossary-un-initialized-value">un-initialized value</a> of this attribute MUST be <code>""</code> (the empty string).</p>
 						</dd>
 					</dl>
-				</section>
+				</section>  <!-- interface-InputEvent -->
 
 				<section id="events-inputevent-event-order">
 					<h4>Input Event Order</h4>
@@ -4273,7 +4273,7 @@
 						</tr>
 					</table>
 
-				</section>
+				</section>  <!-- events-inputevent-event-order -->
 				
 				<p>The Input event types are listed below.</p>
 
@@ -4385,7 +4385,7 @@
 					</dl>
 				</div><!-- input -->
 
-			</section>
+			</section>  <!-- events-inputevents -->
 
 			<section id="events-keyboardevents">
 				<h3>Keyboard Event Types</h3>
@@ -4537,7 +4537,7 @@
 
 						<dt>boolean getModifierState()</dt>
 						<dd>
-							<p>Queries the state of a modifier using a key value. See also <a href="#keys-Modifiers">Modifier keys</a>.</p>
+							<p>Queries the state of a modifier using a key value. See also <a href="#keys-modifiers">Modifier keys</a>.</p>
 
 							<dl class="parameters">
 								<dt>DOMString keyArg</dt>
@@ -4566,7 +4566,7 @@
 						</dd>
 
 					</dl>
-				</section>
+				</section>  <!-- interface-KeyboardEvent -->
 
 				<div class="warning">
 					<p><strong>Warning!</strong></p>
@@ -4667,7 +4667,7 @@
 						For example, a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event for the <a href="#key-Tab"><code class="key">'Tab'</code></a> key
 						will likely have a different <a class="def" href="#glossary-event-target">event target</a> than the  <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>
 						event on the same keystroke.</p>
-				</section>
+				</section>  <!-- events-keyboard-event-order -->
 
 				<p>The keyboard event types are listed below.</p>
 
@@ -4862,7 +4862,7 @@
 						</dd>
 					</dl>
 				</div>
-			</section>
+			</section>  <!-- events-keyboardevents -->
 
 			<section id="events-compositionevents">
 				<h3>Composition Event Types</h3>
@@ -4910,7 +4910,7 @@
 							<p>The <a class="def" href="#glossary-un-initialized-value">un-initialized value</a> of this attribute MUST be <code>""</code> (the empty string).</p>
 						</dd>
 					</dl>
-				</section>
+				</section>  <!-- interface-CompositionEvent -->
 
 				<section id="events-composition-event-order">
 					<h4>Composition Event Order</h4>
@@ -4934,7 +4934,7 @@
 							<td></td>
 						</tr>
 					</table>
-				</section>
+				</section>  <!-- events-composition-event-order -->
 
 				<section id="handwriting">
 					<h4>Handwriting Recognition Systems</h4>
@@ -4971,7 +4971,7 @@
 							<td><code>'text'</code></td>
 						</tr>
 					</table>
-				</section>
+				</section>  <!-- handwriting -->
 
 				<section id="events-composition-event-canceling">
 					<h4>Canceling Composition Events</h4>
@@ -5028,7 +5028,7 @@
 							<td></td>
 						</tr>
 					</table>
-				</section>
+				</section>  <!-- events-composition-event-canceling -->
 
 				<section id="events-composition-event-key-events">
 					<h4>Key Events During Composition</h4>
@@ -5113,7 +5113,7 @@
 						</tr>
 					</table>
 
-				</section>
+				</section>  <!-- events-composition-event-key-events -->
 				
 				<section id="events-composition-event-input-events">
 					<h4>Input Events During Composition</h4>
@@ -5145,7 +5145,7 @@
 					</table>
 					
 					<p class="note"><strong>Note:</strong> Most IMEs do not support canceling updates during a composition session.</p>
-				</section>
+				</section>  <!-- events-composition-event-input-events -->
 				
 				<p>The composition event types are listed below.</p>
 
@@ -5361,9 +5361,9 @@
 						</dd>
 					</dl>
 				</div>
-			</section>
-
-		</section>
+			</section>  <!-- events-compositionevents -->
+
+		</section>  <!-- event-definitions -->
 
 	</section>  <!-- events-module -->
 
@@ -5420,7 +5420,7 @@
 					class="key">'Shift'</code> key might bear the symbol <code class="glyph">&#x21E7;</code>, which has the <a class="def" href="#glossary-unicode-code-point">Unicode code point</a> <code class="char">
 					'\u21E7'</code>, but pressing the <code class="key">'Shift'</code> key will not produce this character value, and there is no <a class="def" href="#glossary-unicode-code-point">
 					Unicode code point</a> for <code class="key">'Shift'</code>.</p>
-			</section>
+			</section>  <!-- key-legends -->
 
 			<section id="keyboard-layout">
 				<h3>Keyboard Layout</h3>
@@ -5465,7 +5465,7 @@
 						<img src='images/ISOIEC-9995-3-FCD-2009A.svg' width="900" height="300" />
 						<figcaption>A graphical depiction of an ISO standard defining layouts of computer keyboards, ISO/IEC 9995, parts 2 and 3.</figcaption>
 					</figure>
-				</section>
+				</section>  <!-- keyboard-desktop -->
 
 				<section id="keyboard-mobile">
 					<h4>Mobile Keypads</h4>
@@ -5483,7 +5483,7 @@
 						<img src='images/ISOIEC-9995-8-2006.svg' width="180" height="240" />
 						<figcaption>A graphical depiction of an ISO standard defining layouts of numeric keypads, with distribution of letters on the keys, ISO/IEC 9995-8:2006.</figcaption>
 					</figure>
-				</section>
+				</section>  <!-- keyboard-mobile -->
 
 				<section id="remote-control">
 					<h4>Media Remote Controls</h4>
@@ -5500,7 +5500,7 @@
 						<figcaption>A graphical depiction of a media remote control, with buttons mapped to specific keys values.</figcaption>
 					</figure>
 
-				</section>
+				</section>  <!-- remote-control -->
 
 				<section id="keyboard-chording-virtual">
 					<h4>Virtual Keyboards and Chording Keyboards</h4>
@@ -5520,11 +5520,11 @@
 						<code class="key">'CapsLock'</code></a>, <a href="#key-NumLock"><code class="key">'NumLock'</code></a>, and <a href="#key-SymbolLock"><code class="key">
 						'SymbolLock'</code></a> are RECOMMENDED for the keys which switch between different modes.</p>
 
-				</section>
-
-			</section>
-
-		</section>
+				</section>  <!-- keyboard-chording-virtual -->
+
+			</section>  <!-- keyboard-layout -->
+
+		</section><!-- keyboard-input -->
 
 		<section id="keys-keyvalues">
 			<h2>Key Values</h2>
@@ -5597,7 +5597,7 @@
 
 				<div class="example">
 					<div class="example-title"></div>
-					<pre><code>if ( ( event.charCode == 45 || event.charCode == 36 ) ||
+<pre><code>if ( ( event.charCode == 45 || event.charCode == 36 ) ||
      ( event.charCode &gt;= 48 &amp;&amp; event.charCode &lt;= 57 ) ||
      ( event.charCode &gt;= 96 &amp;&amp; event.charCode &lt;= 105 ) ) {
    <span class="comment">// minus sign, dollar sign, and numeric characters from keyboard and numpad</span>
@@ -5619,7 +5619,7 @@
 
 				<div class="example">
 					<div class="example-title"></div>
-					<pre><code>if ( event.key == "-" || event.key.match("\p{Sc}") || event.key.match("\p{N}") ) {
+<pre><code>if ( event.key == "-" || event.key.match("\p{Sc}") || event.key.match("\p{N}") ) {
    <span class="comment">// minus sign, any currency symbol, and numeric characters (regardless of key location)</span>
    <span class="comment">// ...</span>
 }
@@ -5645,9 +5645,9 @@
 
 				<p>To facilitate this, implementations SHOULD support Unicode range detection using regular expressions, in a manner such as the Perl Compatible Regular Expressions
 					(PCRE) [<a href="#references-pcre">PCRE</a>].</p>
-			</section>
-
-			<section id="keys-Modifiers">
+			</section>  <!-- keys-unicode -->
+
+			<section id="keys-modifiers">
 				<h3>Modifier keys</h3>
 
 				<p>Keyboard input uses modifier keys to change the normal behavior of a key.  Like other keys, modifier keys generate <a class="eventtype" href="#event-type-keydown">
@@ -5910,9 +5910,9 @@
 					key, acts as the <code class="key">'Del'</code> key, and the value of the key value will match the most appropriate function of the key in its current modified
 					state.</p>
 
-			</section>
-
-			<section id="keys-DeadKeys">
+			</section>  <!-- keys-modifiers -->
+
+			<section id="keys-dead">
 				<h3>Dead keys</h3>
 
 				<p>Some keyboard input uses <a class="def" href="#glossary-dead-key">dead keys</a> for the input of composed character sequences. Unlike the handwriting sequence,
@@ -6080,7 +6080,7 @@
 						</tr>
 					</table>
 				</div>
-			</section>
+			</section>  <!-- keys-dead -->
 
 			<section id="keys-IME">
 				<h3>Input Method Editors</h3>
@@ -6371,8 +6371,8 @@
 				<p class="note"><strong>Note:</strong> Some <a class="def" href="#glossary-ime">input method editors</a> (such as on the MacOS operating system) might set an <a class="def" href="#glossary-empty-string">
 					empty string</a> to the composition data attribute before canceling a composition.</p>
 
-				<h4><a id="keys-IME_keys" href="#keys-IME_keys">6.2.4.1 Input Method Editor mode keys</a></h4>
-				<div>
+				<section id="keys-IME-keys">
+					<h4>Input Method Editor mode keys</h4>
 
 					<p>Some keys on certain devices are intended to activate <a class="def" href="#glossary-ime">input method editor</a> functionality, or to change the mode of an active
 						<a class="def" href="#glossary-ime">input method editor</a>.  Custom keys for this purpose can be defined for different devices or language modes. The keys defined
@@ -6391,10 +6391,10 @@
 
 					<p class="note"><strong>Note:</strong> Keys with <a class="def" href="#glossary-ime">input method editor</a> functions are not restricted to that purpose, and can have other device- or implementation-specific
 						purposes.</p>
-				</div>
-			</section>
-
-			<section id="keys-cancelable_keys">
+				</section>  <!-- keys-IME-keys -->
+			</section>  <!-- keys-IME -->
+
+			<section id="keys-cancelable-keys">
 				<h3>Default actions and cancelable keyboard events</h3>
 
 				<p>Canceling the <a class="def" href="#glossary-default-action">default action</a> of a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event
@@ -6592,9 +6592,9 @@
 						</tr>
 					</table>
 				</div>
-			</section>
-
-			<section id="keys-Guide">
+			</section>  <!-- keys-cancelable-keys -->
+
+			<section id="keys-guidelines">
 				<h3>Guidelines for selecting and defining key values</h3>
 
 				<p><strong>This section is normative.</strong></p>
@@ -6647,8 +6647,8 @@
 							</li>
 					</ul>
 				</div>
-			</section>
-		</section>
+			</section>  <!-- keys-guidelines -->
+		</section>  <!-- keys-keyvalues -->
 
 		<section id="key-value-tables">
 			<h3>Key Value Tables</h3>
@@ -6756,7 +6756,7 @@
 					</p>
 			</section><!-- keys-whitespace -->
 
-			<section id="keys-navication">
+			<section id="keys-navigation">
 				<h4>Navigation Keys</h4>
 				<div id="key-table-navigation" class="key-table">
 					<key name="ArrowDown">The down arrow key, to navigate or traverse downward.</key>
@@ -7092,7 +7092,7 @@
 
 			</section><!-- keys-media-controller -->
 
-		</section>
+		</section>  <!-- key-value-tables -->
 
 	</section>  <!-- keys -->
 
@@ -9830,8 +9830,8 @@
 					<a class="normative" href="http://user.it.uu.se/~jan/html2ps.html">html2ps</a>,
 				which was previously used to generate PostScript versions of the specification.
 				</p>
-		</section>
-	</section>
+		</section>  <!-- acknowledgements-Productions -->
+	</section>  <!-- acknowledgements-contributors -->
 
 	<!-- Appendix H: References ========================================================-->
 	<section id="references">
@@ -10109,7 +10109,7 @@
 					</dd>
 			</dl>
 		</section>
-	</section>
+	</section>  <!-- references -->
 
   </body>
 </html>