Confirmed users
978
edits
No edit summary |
m (format editing) |
||
| Line 59: | Line 59: | ||
=== Proposal: Enhance WebTelephony API to hold a call === | === Proposal: Enhance WebTelephony API to hold a call === | ||
interface nsIDOMTelephony : nsIDOMEventTarget | |||
{ | { | ||
nsIDOMTelephonyCall dial(in DOMString number); | |||
attribute boolean muted; | |||
attribute boolean speakerEnabled; | |||
// The call that is "active", i.e. receives microphone input and tones | |||
// generated via startTone. | |||
readonly attribute jsval active; | |||
// Array of all calls that are currently connected. | |||
readonly attribute jsval calls; | |||
void startTone(in DOMString tone); | |||
void stopTone(); | |||
attribute nsIDOMEventListener onincoming; | |||
attribute nsIDOMEventListener oncallschanged; | |||
}; | }; | ||
interface nsIDOMTelephonyCall : nsIDOMEventTarget | interface nsIDOMTelephonyCall : nsIDOMEventTarget | ||
{ | { | ||
readonly attribute DOMString number; | |||
// "dialing", "ringing", "busy", "connecting", "connected", "disconnecting", "disconnected", "incoming" | |||
// Add new states: "holding", "held", "resuming" | |||
readonly attribute DOMString state; | |||
void answer(); | |||
void hangUp(); | |||
//make a "connected" call into "held" | |||
void holdCall(); | |||
//make a "held" call back to "connected" | |||
void resumeCall(); | |||
attribute nsIDOMEventListener onstatechange; | |||
attribute nsIDOMEventListener ondialing; | |||
attribute nsIDOMEventListener onringing; | |||
attribute nsIDOMEventListener onbusy; | |||
attribute nsIDOMEventListener onconnecting; | |||
attribute nsIDOMEventListener onconnected; | |||
attribute nsIDOMEventListener ondisconnecting; | |||
attribute nsIDOMEventListener ondisconnected; | |||
// attribute nsIDOMEventListener onincoming; | |||
/* new events */ | |||
attribute nsIDOMEventListener onholding; | |||
attribute nsIDOMEventListener onheld; | |||
attribute nsIDOMEventListener onresuming; | |||
}; | }; | ||