Backed out changesets 73f3ce609c23 and 990a21978a2d (bug 951431) because they were...
[gecko.git] / dom / webidl / AudioChannel.webidl
blob215ec0b65befed17ec05c12fcdb56e92664a6cb5
1 /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this
4  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
5  */
7 // AudioChannels are used by:
8 // * HTMLMediaElement
9 // * AudioContext (WebAudio)
10 // When used, it has to throw an exception if the app tries to change the audio
11 // channel type without the permission (manifest file for B2G apps).
12 // The supported values are:
13 // * normal (default value)
14 //   Automatically paused if "notification" or higher priority channel
15 //   is played
16 //   Use case: normal applications
17 // * content
18 //   Automatically paused if "notification" or higher priority channel
19 //   is played. Also paused if another app starts using "content"
20 //   channel. Using this channel never affects applications using
21 //   the "normal" channel.
22 //   Use case: video/audio players
23 // * notification
24 //   Automatically paused if "alarm" or higher priority channel is played.
25 //   Use case: New email, incoming SMS
26 // * alarm
27 //   Automatically paused if "telephony" or higher priority channel is
28 //   played.
29 //   User case: Alarm clock, calendar alarms
30 // * telephony
31 //   Automatically paused if "ringer" or higher priority
32 //   channel is played.
33 //   Use case: dialer, voip
34 // * ringer
35 //   Automatically paused if "publicnotification" or higher priority
36 //   channel is played.
37 //   Use case: dialer, voip
38 // * publicnotification
39 //   Always plays in speaker, even when headphones are plugged in.
40 //   Use case: Camera shutter sound.
41 enum AudioChannel {
42   "normal",
43   "content",
44   "notification",
45   "alarm",
46   "telephony",
47   "ringer",
48   "publicnotification",