@@ -164,17 +164,15 @@ <h2 id="requestMIDIAccess">requestMIDIAccess()</h2>
164
164
scenarios, this permission may have already been implicitly or
165
165
explicitly granted, in which case this prompt may not appear.
166
166
If the user gives express permission or the call is otherwise
167
- approved, the vended Promise's < var > resolveCallback</ var > is invoked, as a < code > < a > MIDISuccessCallback</ a > </ code > (i.e., with a
168
- < code > < a > MIDIAccess</ a > </ code > object and a < code > < a > MIDIOptions</ a > </ code > object as its arguments. The
167
+ approved, the vended Promise is rejected. The
169
168
underlying system may choose to allow the user to select
170
169
specific MIDI interfaces to expose to this API (i.e. pick
171
170
and choose interfaces on an individual basis), although
172
171
this is not required. The system may also choose to prompt
173
172
(or not) based on whether system exclusive support is
174
173
requested, as system exclusive has greater privacy and
175
174
security implications.</ p >
176
- < p > If the user declines or the call is denied for any other reason, the Promise's
177
- < var > rejectCallback</ var > (if any) is invoked with a < code > < a > DOMException</ a > </ code > parameter.
175
+ < p > If the user declines or the call is denied for any other reason, the Promise is rejected with a < code > < a > DOMException</ a > </ code > parameter.
178
176
</ p >
179
177
< p >
180
178
When the < dfn id ="dom-navigator-requestmidiaccess ">
@@ -242,7 +240,6 @@ <h2 id="MIDIOptions"><a>MIDIOptions</a> dictionary</h2>
242
240
243
241
< dd >
244
242
< p > This member informs the system whether the ability to send and receive system exclusive messages is requested or allowed on a given < a > MIDIAccess</ a > object. On the option passed to < code > < a > requestMIDIAccess</ a > </ code > , if this member is set to true, but system exclusive support is denied (either by policy or by user action), the access request will fail with a < code > "SecurityError"</ code > error. If this support is not requested (and allowed), the system will throw exceptions if the user tries to send system exclusive messages, and will silently mask out any system exclusive messages received on the port.</ p >
245
- < p > In the < code > options</ code > parameter passed to the resolveCallback, this member indicates whether system exclusive is allowed on the MIDIAccess.</ p >
246
243
</ dd >
247
244
</ dl >
248
245
</ section >
@@ -301,37 +298,6 @@ <h3 id="MIDIOutputMap"><a>MIDIOutputMap</a> Interface</h3>
301
298
}</ pre >
302
299
</ section >
303
300
304
-
305
- < section >
306
- < h2 > < a > MIDISuccessCallback</ a > </ h2 >
307
-
308
- < dl class ="idl "
309
- title ="callback MIDISuccessCallback = void ">
310
- < dt > MIDIAccess access</ dt >
311
-
312
- < dd >
313
- < p >
314
- A < code > < a > MIDIAccess</ a > </ code > object created to provide
315
- script access to the user's MIDI devices. This object is used
316
- to enumerate and obtain access to individual MIDI devices.
317
- < p > < em > Note</ em > : The term "MIDI device" in this specification
318
- refers to a MIDI interface available to the host system; for
319
- example, if a hardware MIDI adapter is connected to the host
320
- system, it will be enumerated as a single device, even if
321
- several MIDI-supporting devices (such as synthesizers or drum
322
- machines) are plugged into hardware MIDI ports on the
323
- adapter.
324
- </ dd >
325
- < dt > MIDIOptions options</ dt >
326
-
327
- < dd >
328
- < p > This parameter describes the options enabled on this < a > MIDIAccess</ a > object.</ p >
329
- </ dd >
330
- </ dl >
331
- </ section >
332
-
333
- </ section >
334
-
335
301
< section >
336
302
< h2 id ="MIDIAccess "> < a > MIDIAccess</ a > Interface</ h2 >
337
303
< p > This interface provides the methods to list MIDI input and output
@@ -491,12 +457,10 @@ <h2 id="MIDIPort"><a>MIDIPort</a> Interface</h2>
491
457
< p > If the port device has a state of
492
458
< code > < a href ="#idl-def-MIDIPortDeviceState.connected "> "connected"</ a > </ code > ,
493
459
when access to the port has been obtained (and the port is ready for
494
- input or output), the vended Promise's < var > resolveCallback</ var > is
495
- invoked with a < code > < a > MIDIPort</ a > </ code > object as its argument.
460
+ input or output), the vended Promise is resolved.
496
461
</ p >
497
462
< p > If access to a connected port is not available (for example, the port is
498
- already in use in an exclusive-access-only platform), the Promise's
499
- < var > rejectCallback</ var > (if any) is invoked.
463
+ already in use in an exclusive-access-only platform), the Promise is rejected (if any) is invoked.
500
464
</ p >
501
465
< p > If < code > open()</ code > is called on a port that is
502
466
< code > < a href ="#idl-def-MIDIPortDeviceState.disconnected "> "disconnected"</ a > </ code > ,
@@ -595,9 +559,8 @@ <h2 id="MIDIPort"><a>MIDIPort</a> Interface</h2>
595
559
request for access to the given MIDI port on the user's system.
596
560
When the port has been closed (and therefore, in exclusive access
597
561
systems, the port is available to other applications), the vended
598
- Promise's < var > resolveCallback</ var > is invoked with the
599
- < code > < a > MIDIPort</ a > </ code > object as its argument. If the port is
600
- disconnected, the Promise's < var > rejectCallback</ var > (if any) is invoked.</ p >
562
+ Promise is resolved. If the port is
563
+ disconnected, the Promise is rejected.</ p >
601
564
< p > When the < code > close()</ code > method is called, the user
602
565
agent MUST run the < dfn > algorithm to close a MIDIPort</ dfn > :</ p >
603
566
0 commit comments