Confirmed users
978
edits
(consolidate and update WebTelephony) |
(consolidate: WebTelephony: DOM API) |
||
| Line 27: | Line 27: | ||
=== DOM API === | === DOM API === | ||
interface nsIDOMTelephony: nsIDOMEventTarget | We can access the phone functionality simply through navigator.mozTelephony. Once we have a reference to that object, we can start placing and recieving calls by the API below. | ||
interface nsIDOMTelephony: nsIDOMEventTarget | |||
{ | { | ||
nsIDOMTelephonyCall dial(in DOMString number); | nsIDOMTelephonyCall dial(in DOMString number); | ||
| Line 52: | Line 54: | ||
readonly attribute DOMString number; | readonly attribute DOMString number; | ||
// "dialing", "alerting", "busy", "connecting", "connected", "disconnecting", "disconnected", "incoming", "holding", "held", "resuming" | // "dialing", "alerting", "busy", "connecting", "connected", "disconnecting", | ||
// "disconnected", "incoming", "holding", "held", "resuming" | |||
readonly attribute DOMString state; | readonly attribute DOMString state; | ||
// functions to mediate a call. | |||
void answer(); | void answer(); | ||
void hangUp(); | void hangUp(); | ||
void hold(); | void hold(); | ||
void resume(); | void resume(); | ||