Bug 942104 - Add an event "ondiscoverystatechanged", r=gyeh, sr=mrbkap

This commit is contained in:
Eric Chou 2013-11-30 20:20:17 +08:00
parent 287dc32d62
commit d3a0fe86e9
4 changed files with 8 additions and 0 deletions

View File

@ -684,6 +684,7 @@ GK_ATOM(ondisabled, "ondisabled")
GK_ATOM(ondischargingtimechange, "ondischargingtimechange")
GK_ATOM(ondisconnected, "ondisconnected")
GK_ATOM(ondisconnecting, "ondisconnecting")
GK_ATOM(ondiscoverystatechanged, "ondiscoverystatechanged")
GK_ATOM(ondownloading, "ondownloading")
GK_ATOM(onDOMActivate, "onDOMActivate")
GK_ATOM(onDOMAttrModified, "onDOMAttrModified")

View File

@ -147,6 +147,7 @@ public:
SendMediaPlayStatus(const MediaPlayStatus& aMediaPlayStatus, ErrorResult& aRv);
IMPL_EVENT_HANDLER(devicefound);
IMPL_EVENT_HANDLER(discoverystatechanged);
IMPL_EVENT_HANDLER(a2dpstatuschanged);
IMPL_EVENT_HANDLER(hfpstatuschanged);
IMPL_EVENT_HANDLER(pairedstatuschanged);

View File

@ -89,6 +89,11 @@ extern bool gBluetoothDebugFlag;
*/
#define PAIRED_STATUS_CHANGED_ID "pairedstatuschanged"
/**
* This event would be fired when discovery procedure starts or stops.
*/
#define DISCOVERY_STATE_CHANGED_ID "discoverystatechanged"
/**
* When receiving a query about current play status from remote device, we'll
* dispatch an event.

View File

@ -49,6 +49,7 @@ interface BluetoothAdapter : EventTarget {
readonly attribute any uuids;
attribute EventHandler ondevicefound;
attribute EventHandler ondiscoverystatechanged;
// Fired when pairing process is completed
attribute EventHandler onpairedstatuschanged;