Index

Global

Members

appWindowFactory

DatePicker

DatePicker is a html/js "widget" which will display all the days of a given month and allow selection of one specific day. It also implements controls to travel between months and jump into arbitrary time.

The DatePicker itself contains no UI for the controls.

Example usage:

// the container will have elements for the month // added and removed from it. var picker = new DatePicker(container);

// EVENTS:

// called when the user clicks a day in the calendar. picker.onvaluechange = function(date) {}

// called when the month of the calendar changes. // NOTE: at this time this can only happen programmatically // so there is only for control flow. picker.onmonthchange = function(date) {}

// display a given year/month/date on the calendar the month // is zero based just like the JS date constructor. picker.display(2012, 0, 2);

// move to the next month. picker.next();

// move to the previous month picker.previous();

FtuPing

A simple ping that is kicked off on first time use

homescreenLauncher

lockScreenWindowManager

OperatorVariant

Singleton object that helps to set some carrier-specific settings on boot. Detects the ICC cards on boot and creates objects in charge of setting some operator-specific settings relying on the ICC card.

Rocketbar

The Rocketbar is a system-wide URL/search/title bar.

secureWindowFactory

secureWindowManager

SpinDatePicker

SpinDatePicker is a html/js "widget" which enables users pick a specific date. It display the date in the way based on the language setting.

The SpinDatePicker itself contains no UI for the controls.

Example usage:

// All necessary UI elements are contained in the root element. var picker = new SpinDatePicker(root); picker.value = new Date(); // after users pick a date var newDate = picker.value;

systemDialogManager

ValuePicker

base widget used in ValueSelector and SpinDatePicker widget

Methods

debug()

Debug method

debug()

Debug method

DownloadNotification(download)

This is the constructor that will represent a download notification
in the system

Parameters:
Name Type Description
download Object

object provided by the API.

encodeHandoverRequest()

encodeHandoverRequest(): returns a NDEF message containing a Handover
Request. Only a Bluetooth AC will be added to the Handover Request.
'mac': MAC address (string). 'cps': Carrier Power State.
'rnd': Random value for collision resolution

encodeHandoverSelect()

encodeHandoverSelect(): returns a NDEF message containing a Handover
Select. Only a Bluetooth AC will be added to the Handover Select.
'mac': MAC address (string). 'cps': Carrier Power State.
'cps': Carrier Power State

parseBluetoothSSP()

parseBluetoothSSP(): Parses a Carrier Data Record that contains a
Bluetooth Secure Simple Pairing record (NFCForum-AD-BTSSP_1.0).
'cdr': Carrier Data Record. Returns an object with the following
attributes:



  • mac: MAC address (string representation)

  • localName: Local name (optional)

parseHandoverNDEF()

parseHandoverNDEF(): parse a NDEF message containing a handover message.
'ndefMsg' is an Array of MozNDEFRecord. Only 'Hr' and 'Hs' records are
parsed (NFCForum-TS-ConnectionHandover_1_2.doc)
The result is an object with the following attributes:



  • type: either 'Hr' (Handover Request) or 'Hs' (Handover Select)

  • majorVersion

  • minorVersion

  • cr: Collision resolution value. This value is only present
    for a 'Hr' record


  • ac: Array of Alternate Carriers. Each object of this array has
    the following attributes:
    - cps: Carrier Power State
    - cdr: Carrier Data Record: MozNDEFRecord containing further
    info


searchForBluetoothAC()

searchForBluetoothAC(): searches a Handover message for an
Alternative Carrier that contains a Bluetooth profile.
Parameter 'h' is the result of the parse() function.
Returns null if no Bluetooth AC could be found, otherwise
returns a MozNDEFRecord.

Type Definitions

ActivityConfig

Activity Config

Properties:
Name Type Description
manifestURL String

The manifestURL of the activity

url String

The URL of the activity handling page

isActivity Boolean
inline Boolean

The disposition of the activty is inline or not

AppConfig

App Config

Properties:
Name Type Argument Default Description
manifestURL String optional 

The manifestURL of the app

url String

The URL of the activity handling page

origin String

The origin of the app

stayBackground Boolean optional  false

This app is launched at background or not. Usually this means it's a request from system message.

changeURL Boolean optional  false

Need to change the URL of the running app or not. If it's true, we only change the URL when the app is not running at foreground.

BrowserConfig

Browser Configuration

Properties:
Name Type Description
origin String

the same as appURL.

manifestURL String

the same as manifestURL.

manifest Object

the parsed manifest object. If the app is not an entry point app, the manifest would be the reference of application manifest stored in Applications module. But if the app is an entry point app, we will do deep clone to generate a new object and replace the properties of entry point to proper position.

name String

the name of the app, retrieved from manifest.

oop Boolean

Indicate it's running out of process or in process.