зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1112471 - Part 1: Introduce a new API for getting icc service state. r=hsinyi
This commit is contained in:
Родитель
eb08a2be94
Коммит
d66019a004
|
@ -58,7 +58,7 @@ interface nsIIccChannelCallback : nsISupports
|
|||
/**
|
||||
* XPCOM component (in the content process) that provides the ICC information.
|
||||
*/
|
||||
[scriptable, uuid(bf985ee1-14c9-43c6-a471-8ab52fb24b0d)]
|
||||
[scriptable, uuid(821bda2b-7abd-44c6-813e-d4bc68d73a0c)]
|
||||
interface nsIIccProvider : nsISupports
|
||||
{
|
||||
// MUST match enum IccCardState in MozIcc.webidl!
|
||||
|
@ -128,6 +128,9 @@ interface nsIIccProvider : nsISupports
|
|||
const unsigned long CARD_MVNO_TYPE_SPN = 1;
|
||||
const unsigned long CARD_MVNO_TYPE_GID = 2;
|
||||
|
||||
// MUST match with enum IccService in MozIcc.webidl
|
||||
const unsigned long CARD_SERVICE_FDN = 0;
|
||||
|
||||
/**
|
||||
* Called when a content process registers receiving unsolicited messages from
|
||||
* RadioInterfaceLayer in the chrome process. Only a content process that has
|
||||
|
@ -239,4 +242,8 @@ interface nsIIccProvider : nsISupports
|
|||
in nsIDOMWindow window,
|
||||
in unsigned long mvnoType,
|
||||
in DOMString mvnoData);
|
||||
|
||||
nsISupports getServiceState(in unsigned long clientId,
|
||||
in nsIDOMWindow window,
|
||||
in unsigned long service);
|
||||
};
|
||||
|
|
|
@ -89,6 +89,11 @@ enum IccMvnoType
|
|||
"gid"
|
||||
};
|
||||
|
||||
enum IccService
|
||||
{
|
||||
"fdn"
|
||||
};
|
||||
|
||||
dictionary IccUnlockCardLockOptions
|
||||
{
|
||||
required IccLockType lockType;
|
||||
|
@ -331,4 +336,17 @@ interface MozIcc : EventTarget
|
|||
*/
|
||||
[Throws]
|
||||
DOMRequest matchMvno(IccMvnoType mvnoType, DOMString matchData);
|
||||
|
||||
/**
|
||||
* Retrieve the the availability of an icc service.
|
||||
*
|
||||
* @param service
|
||||
* Identifies the service type.
|
||||
*
|
||||
* @return a Promise
|
||||
* If succeeds, the promise is resolved with boolean indicating the
|
||||
* availability of the service. Otherwise, rejected with a DOMError.
|
||||
*/
|
||||
[NewObject, Throws]
|
||||
Promise<boolean> getServiceState(IccService service);
|
||||
};
|
||||
|
|
Загрузка…
Ссылка в новой задаче