B2G/Bluetooth/WebBluetooth-v2/BluetoothAdapterEvent: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
Line 5: Line 5:
  interface BluetoothAdapterEvent : Event
  interface BluetoothAdapterEvent : Event
  {
  {
  readonly attribute BluetoothAdapter adapter;
   readonly attribute boolean isDefault;
   readonly attribute boolean isDefault;
  readonly attribute BluetoothAdapter? adapter;
  readonly attribute DOMString? address;
  };
  };



Revision as of 03:08, 21 March 2014

Overview

BluetoothAdapterEvent is carried as the argument of manager.onadapteradded event handler. Applications can get the added BluetoothAdapter object and knows whether the added adapter is default adapter.

Interface

interface BluetoothAdapterEvent : Event
{
  readonly attribute boolean isDefault;
  readonly attribute BluetoothAdapter? adapter;
  readonly attribute DOMString? address;
};

Properties

adapter

Description
The added adapter.
Value type
BluetoothAdapter

isDefault

Description
Whether the added adapter is default adapter (true) or not (false).
Value type
boolean