dom/webidl/TelephonyCall.webidl

branch
TOR_BUG_9701
changeset 15
b8a032363ba2
equal deleted inserted replaced
-1:000000000000 0:c5ba48417ffa
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 */
6
7 [Pref="dom.telephony.enabled"]
8 interface TelephonyCall : EventTarget {
9 // Indicate which service the call comes from.
10 readonly attribute unsigned long serviceId;
11
12 readonly attribute DOMString number;
13
14 // In CDMA networks, the 2nd waiting call shares the connection with the 1st
15 // call. We need an additional attribute for the 2nd number.
16 readonly attribute DOMString? secondNumber;
17
18 readonly attribute DOMString state;
19
20 // The property "emergency" indicates whether the call number is an emergency
21 // number. Only the outgoing call could have a value with true and it is
22 // available after dialing state.
23 readonly attribute boolean emergency;
24
25 // Indicate whether the call state can be switched between "connected" and
26 // "held".
27 readonly attribute boolean switchable;
28
29 // Indicate whether the call can be added into TelephonyCallGroup.
30 readonly attribute boolean mergeable;
31
32 readonly attribute DOMError? error;
33
34 readonly attribute TelephonyCallGroup? group;
35
36 [Throws]
37 void answer();
38 [Throws]
39 void hangUp();
40 [Throws]
41 void hold();
42 [Throws]
43 void resume();
44
45 attribute EventHandler onstatechange;
46 attribute EventHandler ondialing;
47 attribute EventHandler onalerting;
48 attribute EventHandler onconnecting;
49 attribute EventHandler onconnected;
50 attribute EventHandler ondisconnecting;
51 attribute EventHandler ondisconnected;
52 attribute EventHandler onholding;
53 attribute EventHandler onheld;
54 attribute EventHandler onresuming;
55 attribute EventHandler onerror;
56
57 // Fired whenever the group attribute changes.
58 attribute EventHandler ongroupchange;
59 };

mercurial