Skip to content

Commit 3c6f6de

Browse files
author
Raphael Kubo da Costa
committed
Make NotAllowedError point to its definition in WebIDL.
1 parent e48a02e commit 3c6f6de

File tree

2 files changed

+24
-9
lines changed

2 files changed

+24
-9
lines changed

index.bs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ The static {{DeviceOrientationEvent/requestPermission()}} operation, when invoke
203203
<a>relevant settings object</a>'s <a for="environment settings object">origin</a>.
204204

205205
<li><p>If <var>permission</var> is "<code>default</code>" and the method call was not <a>triggered by user activation</a>, then reject <var>promise</var> with a
206-
<code>NotAllowedError</code> exception and abort these steps.
206+
{{NotAllowedError!!exception}} {{DOMException}} and abort these steps.
207207

208208
<li><p>If <var>permission</var> is "<code>default</code>", ask the user whether sharing device orientation
209209
for the <a>relevant settings object</a>'s
@@ -391,7 +391,7 @@ The static {{DeviceMotionEvent/requestPermission()}} operation, when invoked, mu
391391
<a>relevant settings object</a>'s <a for="environment settings object">origin</a>.
392392
393393
<li><p>If <var>permission</var> is "<code>default</code>" and the method call was not <a>triggered by user activation</a>, then reject <var>promise</var> with a
394-
<code>NotAllowedError</code> exception and abort these steps.
394+
{{NotAllowedError!!exception}} {{DOMException}} and abort these steps.
395395
396396
<li><p>If <var>permission</var> is "<code>default</code>", ask the user whether sharing device motion
397397
for the <a>relevant settings object</a>'s

index.html

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1219,9 +1219,8 @@
12191219
background-attachment: fixed;
12201220
}
12211221
</style>
1222-
<meta content="Bikeshed version df1bf04b71c9fb8a3d724e46fc13f9cf7065df60" name="generator">
1222+
<meta content="Bikeshed version 4d208866a95a1121fceca549a36bfb09c5bf1705" name="generator">
12231223
<link href="http://www.w3.org/TR/orientation-event/" rel="canonical">
1224-
<meta content="d6ab89b3dce1629e15a0dc55ee88345fed650ffa" name="document-revision">
12251224
<style>/* style-md-lists */
12261225

12271226
/* This is a weird hack for me not yet following the commonmark spec
@@ -1468,7 +1467,7 @@
14681467
<div class="head">
14691468
<p data-fill-with="logo"><a class="logo" href="https://www.w3.org/"> <img alt="W3C" height="48" src="https://www.w3.org/StyleSheets/TR/2016/logos/W3C" width="72"> </a> </p>
14701469
<h1 class="p-name no-ref" id="title">DeviceOrientation Event Specification</h1>
1471-
<h2 class="no-num no-toc no-ref heading settled" id="subtitle"><span class="content">Editor’s Draft, <time class="dt-updated" datetime="2019-04-09">9 April 2019</time></span></h2>
1470+
<h2 class="no-num no-toc no-ref heading settled" id="subtitle"><span class="content">Editor’s Draft, <time class="dt-updated" datetime="2019-04-15">15 April 2019</time></span></h2>
14721471
<div data-fill-with="spec-metadata">
14731472
<dl>
14741473
<dt>This version:
@@ -1515,7 +1514,7 @@ <h2 class="no-num no-toc no-ref heading settled" id="sotd"><span class="content"
15151514
W3C maintains a <a href="https://www.w3.org/2004/01/pp-impl/43696/status" rel="disclosure">public list of any patent disclosures</a> made in connection with the deliverables of the group;
15161515
that page also includes instructions for disclosing a patent.
15171516
An individual who has actual knowledge of a patent which the individual believes contains <a href="https://www.w3.org/Consortium/Patent-Policy/#def-essential">Essential Claim(s)</a> must disclose the information in accordance with <a href="https://www.w3.org/Consortium/Patent-Policy/#sec-Disclosure">section 6 of the W3C Patent Policy</a>. </p>
1518-
<p> This document is governed by the <a href="https://www.w3.org/2018/Process-20180201/" id="w3c_process_revision">1 February 2018 W3C Process Document</a>. </p>
1517+
<p> This document is governed by the <a href="https://www.w3.org/2019/Process-20190301/" id="w3c_process_revision">1 March 2019 W3C Process Document</a>. </p>
15191518
<p></p>
15201519
</div>
15211520
<div data-fill-with="at-risk"></div>
@@ -1686,7 +1685,7 @@ <h3 class="heading settled" data-level="4.1" id="deviceorientation"><span class=
16861685
<li>
16871686
<p>Let <var>permission</var> be <a data-link-type="dfn" href="#permission" id="ref-for-permission">permission</a> for <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#relevant-settings-object" id="ref-for-relevant-settings-object">relevant settings object</a>’s <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#concept-settings-object-origin" id="ref-for-concept-settings-object-origin">origin</a>. </p>
16881687
<li>
1689-
<p>If <var>permission</var> is "<code>default</code>" and the method call was not <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/interaction.html#triggered-by-user-activation" id="ref-for-triggered-by-user-activation">triggered by user activation</a>, then reject <var>promise</var> with a <code>NotAllowedError</code> exception and abort these steps. </p>
1688+
<p>If <var>permission</var> is "<code>default</code>" and the method call was not <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/interaction.html#triggered-by-user-activation" id="ref-for-triggered-by-user-activation">triggered by user activation</a>, then reject <var>promise</var> with a <code class="idl"><a class="idl-code" data-link-type="exception" href="https://heycam.github.io/webidl/#notallowederror" id="ref-for-notallowederror">NotAllowedError</a></code> <code class="idl"><a data-link-type="idl" href="https://heycam.github.io/webidl/#idl-DOMException" id="ref-for-idl-DOMException">DOMException</a></code> and abort these steps. </p>
16901689
<li>
16911690
<p>If <var>permission</var> is "<code>default</code>", ask the user whether sharing device orientation
16921691
for the <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#relevant-settings-object" id="ref-for-relevant-settings-object①">relevant settings object</a>’s <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#concept-settings-object-origin" id="ref-for-concept-settings-object-origin①">origin</a> is acceptable. If it is, set <var>permission</var> to "<code>granted</code>", and "<code>denied</code>" otherwise. </p>
@@ -1834,7 +1833,7 @@ <h3 class="heading settled" data-level="4.4" id="devicemotion"><span class="secn
18341833
<li>
18351834
<p>Let <var>permission</var> be <a data-link-type="dfn" href="#permission" id="ref-for-permission②">permission</a> for <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#relevant-settings-object" id="ref-for-relevant-settings-object③">relevant settings object</a>’s <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#concept-settings-object-origin" id="ref-for-concept-settings-object-origin③">origin</a>. </p>
18361835
<li>
1837-
<p>If <var>permission</var> is "<code>default</code>" and the method call was not <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/interaction.html#triggered-by-user-activation" id="ref-for-triggered-by-user-activation①">triggered by user activation</a>, then reject <var>promise</var> with a <code>NotAllowedError</code> exception and abort these steps. </p>
1836+
<p>If <var>permission</var> is "<code>default</code>" and the method call was not <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/interaction.html#triggered-by-user-activation" id="ref-for-triggered-by-user-activation①">triggered by user activation</a>, then reject <var>promise</var> with a <code class="idl"><a class="idl-code" data-link-type="exception" href="https://heycam.github.io/webidl/#notallowederror" id="ref-for-notallowederror①">NotAllowedError</a></code> <code class="idl"><a data-link-type="idl" href="https://heycam.github.io/webidl/#idl-DOMException" id="ref-for-idl-DOMException①">DOMException</a></code> and abort these steps. </p>
18381837
<li>
18391838
<p>If <var>permission</var> is "<code>default</code>", ask the user whether sharing device motion
18401839
for the <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#relevant-settings-object" id="ref-for-relevant-settings-object④">relevant settings object</a>’s <a data-link-type="dfn" href="https://html.spec.whatwg.org/multipage/webappapis.html#concept-settings-object-origin" id="ref-for-concept-settings-object-origin④">origin</a> is acceptable. If it is, set <var>permission</var> to "<code>granted</code>", and "<code>denied</code>" otherwise. </p>
@@ -2283,6 +2282,13 @@ <h3 class="no-num no-ref heading settled" id="index-defined-here"><span class="c
22832282
<li><a href="#ref-for-dom-visibilitystate-visible">5. Security and privacy considerations</a>
22842283
</ul>
22852284
</aside>
2285+
<aside class="dfn-panel" data-for="term-for-idl-DOMException">
2286+
<a href="https://heycam.github.io/webidl/#idl-DOMException">https://heycam.github.io/webidl/#idl-DOMException</a><b>Referenced in:</b>
2287+
<ul>
2288+
<li><a href="#ref-for-idl-DOMException">4.1. deviceorientation Event</a>
2289+
<li><a href="#ref-for-idl-DOMException①">4.4. devicemotion Event</a>
2290+
</ul>
2291+
</aside>
22862292
<aside class="dfn-panel" data-for="term-for-idl-DOMString">
22872293
<a href="https://heycam.github.io/webidl/#idl-DOMString">https://heycam.github.io/webidl/#idl-DOMString</a><b>Referenced in:</b>
22882294
<ul>
@@ -2297,6 +2303,13 @@ <h3 class="no-num no-ref heading settled" id="index-defined-here"><span class="c
22972303
<li><a href="#ref-for-Exposed①">4.4. devicemotion Event</a>
22982304
</ul>
22992305
</aside>
2306+
<aside class="dfn-panel" data-for="term-for-notallowederror">
2307+
<a href="https://heycam.github.io/webidl/#notallowederror">https://heycam.github.io/webidl/#notallowederror</a><b>Referenced in:</b>
2308+
<ul>
2309+
<li><a href="#ref-for-notallowederror">4.1. deviceorientation Event</a>
2310+
<li><a href="#ref-for-notallowederror①">4.4. devicemotion Event</a>
2311+
</ul>
2312+
</aside>
23002313
<aside class="dfn-panel" data-for="term-for-SecureContext">
23012314
<a href="https://heycam.github.io/webidl/#SecureContext">https://heycam.github.io/webidl/#SecureContext</a><b>Referenced in:</b>
23022315
<ul>
@@ -2353,8 +2366,10 @@ <h3 class="no-num no-ref heading settled" id="index-defined-elsewhere"><span cla
23532366
<li>
23542367
<a data-link-type="biblio">[WEBIDL]</a> defines the following terms:
23552368
<ul>
2369+
<li><span class="dfn-paneled" id="term-for-idl-DOMException" style="color:initial">DOMException</span>
23562370
<li><span class="dfn-paneled" id="term-for-idl-DOMString" style="color:initial">DOMString</span>
23572371
<li><span class="dfn-paneled" id="term-for-Exposed" style="color:initial">Exposed</span>
2372+
<li><span class="dfn-paneled" id="term-for-notallowederror" style="color:initial">NotAllowedError</span>
23582373
<li><span class="dfn-paneled" id="term-for-SecureContext" style="color:initial">SecureContext</span>
23592374
<li><span class="dfn-paneled" id="term-for-idl-boolean" style="color:initial">boolean</span>
23602375
<li><span class="dfn-paneled" id="term-for-idl-double" style="color:initial">double</span>
@@ -2374,7 +2389,7 @@ <h3 class="no-num no-ref heading settled" id="normative"><span class="content">N
23742389
<dt id="biblio-secure-contexts">[SECURE-CONTEXTS]
23752390
<dd>Mike West. <a href="https://www.w3.org/TR/secure-contexts/">Secure Contexts</a>. 15 September 2016. CR. URL: <a href="https://www.w3.org/TR/secure-contexts/">https://www.w3.org/TR/secure-contexts/</a>
23762391
<dt id="biblio-webidl">[WEBIDL]
2377-
<dd>Cameron McCormack; Boris Zbarsky; Tobie Langel. <a href="https://heycam.github.io/webidl/">Web IDL</a>. 15 December 2016. ED. URL: <a href="https://heycam.github.io/webidl/">https://heycam.github.io/webidl/</a>
2392+
<dd>Boris Zbarsky. <a href="https://heycam.github.io/webidl/">Web IDL</a>. 15 December 2016. ED. URL: <a href="https://heycam.github.io/webidl/">https://heycam.github.io/webidl/</a>
23782393
</dl>
23792394
<h3 class="no-num no-ref heading settled" id="informative"><span class="content">Informative References</span><a class="self-link" href="#informative"></a></h3>
23802395
<dl>

0 commit comments

Comments
 (0)