|
16 | 16 |
|
17 | 17 | <h1>CSSOM View Module</h1>
|
18 | 18 |
|
19 |
| - <h2 class="no-num no-toc" id="w3c-doctype">Editor's Draft 7 June 2014</h2> |
| 19 | + <h2 class="no-num no-toc" id="w3c-doctype">Editor's Draft 9 June 2014</h2> |
20 | 20 |
|
21 | 21 | <dl>
|
22 | 22 |
|
@@ -83,7 +83,7 @@ <h2 class="no-num no-toc" id="sotd">Status of This Document</h2>
|
83 | 83 | can be found in the <a href="http://www.w3.org/TR/">W3C technical reports
|
84 | 84 | index at http://www.w3.org/TR/.</a></em>
|
85 | 85 |
|
86 |
| -<p>This is the 7 June 2014 Editor's Draft of CSSOM View. Please send |
| 86 | +<p>This is the 9 June 2014 Editor's Draft of CSSOM View. Please send |
87 | 87 | comments to
|
88 | 88 | <a href="mailto:www-style@w3.org?subject=%5Bcssom-view%5D%20">www-style@w3.org</a>
|
89 | 89 | (<a href="http://lists.w3.org/Archives/Public/www-style/">archived</a>)
|
@@ -866,13 +866,28 @@ <h3 id="the-mediaquerylist-interface"><span class="secno">5.2 </span>The <code t
|
866 | 866 | <p>The <dfn id="dom-mediaquerylist-matches" title="dom-MediaQueryList-matches"><code>matches</code></dfn> attribute must return
|
867 | 867 | the associated <a href="#concept-mediaquerylist-matches" title="concept-MediaQueryList-matches">matches state</a>. <!--fingerprint--></p>
|
868 | 868 |
|
869 |
| -<p>When the <dfn id="dom-mediaquerylist-addlistener" title="dom-MediaQueryList-addListener"><code>addListener(<var>listener</var>)</code></dfn> method is invoked |
870 |
| -the user agent must invoke the <code class="external" data-anolis-spec="dom" title="dom-EventTarget-addEventListener"><a href="http://dom.spec.whatwg.org/#dom-eventtarget-addeventlistener">addEventListener</a></code> method |
871 |
| -with <code title="">change</code> as the first argument and <var>listener</var> as the second argument.</p> |
| 869 | +<p>The <dfn id="dom-mediaquerylist-addlistener" title="dom-MediaQueryList-addListener"><code>addListener(<var>listener</var>)</code></dfn> method must run these steps:</p> |
872 | 870 |
|
873 |
| -<p>When the <dfn id="dom-mediaquerylist-removelistener" title="dom-MediaQueryList-removeListener"><code>removeListener(<var>listener</var>)</code></dfn> method is invoked |
874 |
| -the user agent must invoke the <code class="external" data-anolis-spec="dom" title="dom-EventTarget-removeEventListener"><a href="http://dom.spec.whatwg.org/#dom-eventtarget-removeeventlistener">removeEventListener</a></code> method |
875 |
| -with <code title="">change</code> as the first argument and <var>listener</var> as the second argument.</p> |
| 871 | +<ol> |
| 872 | + <li><p>If <var title="">listener</var> is null, terminate these steps. |
| 873 | + <li><p>Append an <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-listener" title="concept-event-listener">event listener</a> |
| 874 | + to the associated list of |
| 875 | + <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-listener" title="concept-event-listener">event listeners</a> with <b>type</b> |
| 876 | + set to <code title="">change</code>, <b>callback</b> set to <var title="">listener</var>, and |
| 877 | + <b>capture</b> set to false, unless there |
| 878 | + already is an <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-listener" title="concept-event-listener">event listener</a> in |
| 879 | + that list with the same <b>type</b>, <b>callback</b>, and <b>capture</b>. |
| 880 | +</ol> |
| 881 | + |
| 882 | +<p>The <dfn id="dom-mediaquerylist-removelistener" title="dom-MediaQueryList-removeListener"><code>removeListener(<var>listener</var>)</code></dfn> method must run these steps:</p> |
| 883 | + |
| 884 | +<ol> |
| 885 | + <li><p>Remove an <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-listener" title="concept-event-listener">event listener</a> |
| 886 | + from the associated list of |
| 887 | + <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-listener" title="concept-event-listener">event listeners</a>, whose |
| 888 | + <b>type</b> is <code title="">change</code>, <b>callback</b> is <var title="">listener</var>, and |
| 889 | + <b>capture</b> is false.</p> |
| 890 | +</ol> |
876 | 891 |
|
877 | 892 | <p class="note">This specification initially had a custom callback mechanism with <code title="dom-MediaQueryList-addListener"><a href="#dom-mediaquerylist-addlistener">addListener</a></code> and
|
878 | 893 | <code title="dom-MediaQueryList-removeListener"><a href="#dom-mediaquerylist-removelistener">removeListener</a></code>, and the callback was invoked with the associated media query list as argument.
|
@@ -900,8 +915,7 @@ <h3 id="the-mediaquerylist-interface"><span class="secno">5.2 </span>The <code t
|
900 | 915 | </tbody>
|
901 | 916 | </table>
|
902 | 917 |
|
903 |
| -<pre class="idl">[<a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-constructor" title="concept-event-constructor">Constructor</a>(DOMString type, optional <a href="#mediaquerylisteventinit">MediaQueryListEventInit</a> eventInitDict), |
904 |
| - Exposed=Window,Worker] |
| 918 | +<pre class="idl">[<a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#concept-event-constructor" title="concept-event-constructor">Constructor</a>(DOMString type, optional <a href="#mediaquerylisteventinit">MediaQueryListEventInit</a> eventInitDict)] |
905 | 919 | interface <dfn id="mediaquerylistevent">MediaQueryListEvent</dfn> : <a class="external" data-anolis-spec="dom" href="http://dom.spec.whatwg.org/#event">Event</a> {
|
906 | 920 | readonly attribute DOMString <a href="#dom-mediaquerylistevent-media" title="dom-MediaQueryListEvent-media">media</a>;
|
907 | 921 | readonly attribute boolean <a href="#dom-mediaquerylistevent-matches" title="dom-MediaQueryListEvent-matches">matches</a>;
|
|
0 commit comments