Bug 804671 - Part 1: IDL for PROVIDE_LOCAL_INFO. r=allstars.chh. sr=jonas

This commit is contained in:
Edgar Chen 2012-11-23 10:18:52 +08:00
parent f14a907820
commit a790a10fbd
2 changed files with 64 additions and 0 deletions

View File

@ -318,6 +318,19 @@ dictionary MozStkPlayTone
boolean isVibrate;
};
dictionary MozStkProvideLocalInfo
{
/**
* Indicate which local information is required.
* It shall be one of following:
* - nsIDOMMozIccManager.STK_LOCAL_INFO_LOCATION_INFO
* - nsIDOMMozIccManager.STK_LOCAL_INFO_IMEI
* - nsIDOMMozIccManager.STK_LOCAL_INFO_DATE_TIME_ZONE
* - nsIDOMMozIccManager.STK_LOCAL_INFO_LANGUAGE
*/
unsigned short localInfoType;
};
dictionary MozStkLocationEvent
{
/**
@ -403,6 +416,10 @@ dictionary MozStkCommand
* options is MozStkDuration.
*
* When typeOfCommand is
* - STK_CMD_PROVIDE_LOCAL_INFO
* options is MozStkProvideLocalInfo.
*
* When typeOfCommand is
* - STK_CMD_POLL_OFF
* options is null.
*
@ -458,6 +475,13 @@ dictionary MozStkResponse
* false: Rejected by User.
*/
boolean hasConfirmed;
/**
* The response for STK_CMD_PROVIDE_LOCAL_INFO
*
* @see MozStkLocalInfo
*/
jsval localInfo;
};
dictionary MozStkCallEvent
@ -493,3 +517,32 @@ dictionary MozStkCallEvent
*/
DOMString error;
};
dictionary MozStkLocalInfo
{
/**
* IMEI information
*/
DOMString imei;
/**
* Location Information
*
* @see MozStkLocationInfo.
*/
jsval locationInfo;
/**
* Date information
*
* @see Date
*/
jsval date;
/**
* Language Information
*
* @see ISO 639-1, Alpha-2 code
*/
DOMString language;
};

View File

@ -45,6 +45,7 @@ interface nsIDOMMozIccManager : nsIDOMEventTarget
const unsigned short STK_CMD_GET_INPUT = 0x23;
const unsigned short STK_CMD_SELECT_ITEM = 0x24;
const unsigned short STK_CMD_SET_UP_MENU = 0x25;
const unsigned short STK_CMD_PROVIDE_LOCAL_INFO = 0x26;
const unsigned short STK_CMD_SET_UP_IDLE_MODE_TEXT = 0x28;
/**
@ -194,6 +195,16 @@ interface nsIDOMMozIccManager : nsIDOMEventTarget
const unsigned short STK_TIME_UNIT_SECOND = 0x01;
const unsigned short STK_TIME_UNIT_TENTH_SECOND = 0x02;
/**
* Local Information list
*
* @see TS 102.223, clause 8.6
*/
const unsigned short STK_LOCAL_INFO_LOCATION_INFO = 0x00;
const unsigned short STK_LOCAL_INFO_IMEI = 0x01;
const unsigned short STK_LOCAL_INFO_DATE_TIME_ZONE = 0x03;
const unsigned short STK_LOCAL_INFO_LANGUAGE = 0x04;
/**
* Send the response back to ICC after an attempt to execute STK Proactive
* Command.