Bug 1171807 - Part 1: Add enums for TelephonyCall::State and TelephonyCallGroup::State (WebIDL). r=hsinyi

This commit is contained in:
Ben Hsu 2015-09-02 05:21:00 +02:00
parent d8541746fb
commit 21d25edc6c
2 changed files with 17 additions and 2 deletions

View File

@ -15,7 +15,7 @@ interface TelephonyCall : EventTarget {
// call. We need an additional attribute for the CDMA waiting call.
readonly attribute TelephonyCallId? secondId;
readonly attribute DOMString state;
readonly attribute TelephonyCallState state;
// The property "emergency" indicates whether the call number is an emergency
// number. Only the outgoing call could have a value with true and it is
@ -56,6 +56,15 @@ interface TelephonyCall : EventTarget {
attribute EventHandler ongroupchange;
};
enum TelephonyCallState {
"dialing",
"alerting",
"connected",
"held",
"disconnected",
"incoming",
};
enum TelephonyCallDisconnectedReason {
"BadNumber",
"NoRouteToDestination",

View File

@ -26,7 +26,7 @@ interface TelephonyCallGroup : EventTarget {
[NewObject, Throws]
Promise<void> resume();
readonly attribute DOMString state;
readonly attribute TelephonyCallGroupState state;
attribute EventHandler onstatechange;
attribute EventHandler onconnected;
@ -34,3 +34,9 @@ interface TelephonyCallGroup : EventTarget {
attribute EventHandler oncallschanged;
attribute EventHandler onerror;
};
enum TelephonyCallGroupState {
"",
"connected",
"held",
};