Bug 1052843 - Part 1: Use enums for MobileRadioState in nsIMobileConnectionService.idl (idl). r=hsinyi

This commit is contained in:
Jessica Jong 2014-10-24 17:12:31 +08:00
parent 4d2e27ecd1
commit cc60ecbca2
2 changed files with 15 additions and 6 deletions

View File

@ -9,7 +9,7 @@
"@mozilla.org/mobileconnection/gonkmobileconnectionservice;1"
%}
[scriptable, uuid(2d574f0e-4a02-11e4-b1b3-cbc14b7608ce)]
[scriptable, uuid(7322619d-9abd-4410-99ce-207da80f9879)]
interface nsIGonkMobileConnectionService : nsIMobileConnectionService
{
void notifyNetworkInfoChanged(in unsigned long clientId, in jsval networkInfo);
@ -27,7 +27,7 @@ interface nsIGonkMobileConnectionService : nsIMobileConnectionService
void notifyOtaStatusChanged(in unsigned long clientId, in DOMString status);
void notifyRadioStateChanged(in unsigned long clientId,
in DOMString radioState);
in long radioState);
void notifyUssdReceived(in unsigned long clientId,
in DOMString message,

View File

@ -236,7 +236,7 @@ already_AddRefed<nsIMobileConnectionService>
NS_CreateMobileConnectionService();
%}
[scriptable, uuid(cfc7d15b-d2c2-4f28-ad9f-b250030c3073)]
[scriptable, uuid(99818dc7-e770-4249-87e2-2de0a928ed08)]
interface nsIMobileConnection : nsISupports
{
/*
@ -304,6 +304,15 @@ interface nsIMobileConnection : nsISupports
const long NETWORK_SELECTION_MODE_AUTOMATIC = 0;
const long NETWORK_SELECTION_MODE_MANUAL = 1;
/**
* Mobile Radio State.
*/
const long MOBILE_RADIO_STATE_UNKNOWN = -1;
const long MOBILE_RADIO_STATE_ENABLING = 0;
const long MOBILE_RADIO_STATE_ENABLED = 1;
const long MOBILE_RADIO_STATE_DISABLING = 2;
const long MOBILE_RADIO_STATE_DISABLED = 3;
readonly attribute unsigned long serviceId;
/**
@ -347,10 +356,10 @@ interface nsIMobileConnection : nsISupports
readonly attribute long networkSelectionMode;
/**
* Current radio state. Possible values are 'enabling', 'enabled',
* 'disabling', 'disabled', null (unknown).
* Current radio state. One of the nsIMobileConnection.MOBILE_RADIO_STATE_*
* values.
*/
readonly attribute DOMString radioState;
readonly attribute long radioState;
/**
* The network types supported by this radio.