Bug 875721 - Part 1: Move iccInfo related attribute/event from mozMobileConnection to mozIccManager (IDL). r=allstars.chh, sr=sicking

This commit is contained in:
Edgar Chen 2013-05-30 18:04:48 +08:00
parent 75a5231698
commit 93ee2195ae
7 changed files with 83 additions and 71 deletions

View File

@ -7,6 +7,7 @@
XPIDL_SOURCES += [
'SimToolKit.idl',
'nsIDOMIccCardLockErrorEvent.idl',
'nsIDOMIccInfo.idl',
'nsIDOMIccManager.idl',
'nsIIccProvider.idl',
'nsINavigatorIccManager.idl',

View File

@ -0,0 +1,45 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsISupports.idl"
[scriptable, uuid(a45c0fe0-c911-11e2-8b8b-0800200c9a66)]
interface nsIDOMMozIccInfo : nsISupports
{
/**
* Integrated Circuit Card Identifier.
*/
readonly attribute DOMString iccid;
/**
* Mobile Country Code (MCC) of the subscriber's home network.
*/
readonly attribute DOMString mcc;
/**
* Mobile Network Code (MNC) of the subscriber's home network.
*/
readonly attribute DOMString mnc;
/**
* Service Provider Name (SPN) of the subscriber's home network.
*/
readonly attribute DOMString spn;
/**
* Network name must be a part of displayed carrier name.
*/
readonly attribute boolean isDisplayNetworkNameRequired;
/**
* Service provider name must be a part of displayed carrier name.
*/
readonly attribute boolean isDisplaySpnRequired;
/**
* Mobile Station ISDN Number (MSISDN) of the subscriber's, aka
* his phone number.
*/
readonly attribute DOMString msisdn;
};

View File

@ -5,11 +5,12 @@
#include "nsIDOMEventTarget.idl"
#include "SimToolKit.idl"
interface nsIDOMEventListener;
interface nsIDOMDOMRequest;
interface nsIDOMContact;
interface nsIDOMDOMRequest;
interface nsIDOMEventListener;
interface nsIDOMMozIccInfo;
[scriptable, builtinclass, uuid(5f405112-4da9-4d4d-942c-4da3cb7928e1)]
[scriptable, builtinclass, uuid(d362bf60-c910-11e2-8b8b-0800200c9a66)]
interface nsIDOMMozIccManager : nsIDOMEventTarget
{
/**
@ -275,6 +276,19 @@ interface nsIDOMMozIccManager : nsIDOMEventTarget
*/
[implicit_jscontext] attribute jsval onstksessionend;
// UICC Card Information.
/**
* Information stored in the device's ICC card.
*/
readonly attribute nsIDOMMozIccInfo iccInfo;
/**
* The 'iccinfochange' event is notified whenever the icc info object
* changes.
*/
[implicit_jscontext] attribute jsval oniccinfochange;
// UICC Card State.
/**

View File

@ -4,11 +4,12 @@
#include "nsISupports.idl"
interface nsIDOMWindow;
interface nsIDOMDOMRequest;
interface nsIDOMContact;
interface nsIDOMDOMRequest;
interface nsIDOMMozIccInfo;
interface nsIDOMWindow;
[scriptable, uuid(5902d9b0-c2be-11e2-8b8b-0800200c9a66)]
[scriptable, uuid(82d25440-c913-11e2-8b8b-0800200c9a66)]
interface nsIIccListener : nsISupports
{
void notifyStkCommand(in DOMString aMessage);
@ -16,12 +17,13 @@ interface nsIIccListener : nsISupports
void notifyIccCardLockError(in DOMString lockType,
in unsigned long retryCount);
void notifyCardStateChanged();
void notifyIccInfoChanged();
};
/**
* XPCOM component (in the content process) that provides the ICC information.
*/
[scriptable, uuid(7131dfbe-9a2c-434d-b6b8-3eebf491ce1a)]
[scriptable, uuid(52fa6780-c913-11e2-8b8b-0800200c9a66)]
interface nsIIccProvider : nsISupports
{
/**
@ -32,6 +34,11 @@ interface nsIIccProvider : nsISupports
void registerIccMsg(in nsIIccListener listener);
void unregisterIccMsg(in nsIIccListener listener);
/**
* UICC Information
*/
readonly attribute nsIDOMMozIccInfo iccInfo;
/**
* Card State
*/

View File

@ -6,13 +6,12 @@
interface nsIDOMEventListener;
interface nsIDOMDOMRequest;
interface nsIDOMMozMobileICCInfo;
interface nsIDOMMozMobileConnectionInfo;
interface nsIDOMMozMobileNetworkInfo;
interface nsIDOMMozMobileCellInfo;
interface nsIDOMMozMobileCFInfo;
[scriptable, builtinclass, uuid(dc010230-c2bc-11e2-8b8b-0800200c9a66)]
[scriptable, builtinclass, uuid(fd26e2e0-c910-11e2-8b8b-0800200c9a66)]
interface nsIDOMMozMobileConnection : nsIDOMEventTarget
{
const long ICC_SERVICE_CLASS_VOICE = (1 << 0);
@ -55,11 +54,6 @@ interface nsIDOMMozMobileConnection : nsIDOMEventTarget
*/
readonly attribute long retryCount;
/**
* Information stored in the device's ICC card.
*/
readonly attribute nsIDOMMozMobileICCInfo iccInfo;
/**
* Information about the voice connection.
*/
@ -232,12 +226,6 @@ interface nsIDOMMozMobileConnection : nsIDOMEventTarget
*/
nsIDOMDOMRequest getCallWaitingOption();
/**
* The 'iccinfochange' event is notified whenever the icc info object
* changes.
*/
[implicit_jscontext] attribute jsval oniccinfochange;
/**
* The 'voicechange' event is notified whenever the voice connection object
* changes.
@ -380,46 +368,6 @@ interface nsIDOMMozMobileCellInfo: nsISupports
readonly attribute unsigned long gsmCellId;
};
[scriptable, uuid(10d5c5a2-d43f-4f94-8657-cf7ccabbab6e)]
interface nsIDOMMozMobileICCInfo : nsISupports
{
/**
* Integrated Circuit Card Identifier.
*/
readonly attribute DOMString iccid;
/**
* Mobile Country Code (MCC) of the subscriber's home network.
*/
readonly attribute DOMString mcc;
/**
* Mobile Network Code (MNC) of the subscriber's home network.
*/
readonly attribute DOMString mnc;
/**
* Service Provider Name (SPN) of the subscriber's home network.
*/
readonly attribute DOMString spn;
/**
* Network name must be a part of displayed carrier name.
*/
readonly attribute boolean isDisplayNetworkNameRequired;
/**
* Service provider name must be a part of displayed carrier name.
*/
readonly attribute boolean isDisplaySpnRequired;
/**
* Mobile Station ISDN Number (MSISDN) of the subscriber's, aka
* his phone number.
*/
readonly attribute DOMString msisdn;
};
[scriptable, uuid(d1b35ad8-99aa-47cc-ab49-2e72b00e39df)]
interface nsIDOMMozMobileCFInfo : nsISupports
{

View File

@ -4,19 +4,17 @@
#include "nsISupports.idl"
interface nsIDOMMozMobileICCInfo;
interface nsIDOMDOMRequest;
interface nsIDOMMozMobileCFInfo;
interface nsIDOMMozMobileConnectionInfo;
interface nsIDOMMozMobileNetworkInfo;
interface nsIDOMMozMobileCFInfo;
interface nsIDOMDOMRequest;
interface nsIDOMWindow;
[scriptable, uuid(529864f0-c2be-11e2-8b8b-0800200c9a66)]
[scriptable, uuid(74361840-c913-11e2-8b8b-0800200c9a66)]
interface nsIMobileConnectionListener : nsISupports
{
void notifyVoiceChanged();
void notifyDataChanged();
void notifyIccInfoChanged();
void notifyUssdReceived(in DOMString message,
in boolean sessionEnded);
void notifyDataError(in DOMString message);
@ -32,7 +30,7 @@ interface nsIMobileConnectionListener : nsISupports
* XPCOM component (in the content process) that provides the mobile
* network information.
*/
[scriptable, uuid(66e7ac90-c2be-11e2-8b8b-0800200c9a66)]
[scriptable, uuid(477d93f0-c913-11e2-8b8b-0800200c9a66)]
interface nsIMobileConnectionProvider : nsISupports
{
/**
@ -44,7 +42,6 @@ interface nsIMobileConnectionProvider : nsISupports
void unregisterMobileConnectionMsg(in nsIMobileConnectionListener listener);
readonly attribute long retryCount;
readonly attribute nsIDOMMozMobileICCInfo iccInfo;
readonly attribute nsIDOMMozMobileConnectionInfo voiceConnectionInfo;
readonly attribute nsIDOMMozMobileConnectionInfo dataConnectionInfo;
readonly attribute DOMString networkSelectionMode;

View File

@ -4,10 +4,10 @@
#include "nsISupports.idl"
interface nsIDOMMozIccInfo;
interface nsIDOMMozMobileConnectionInfo;
interface nsIDOMMozMobileICCInfo;
interface nsIMobileMessageCallback;
interface nsIDOMMozSmsSegmentInfo;
interface nsIMobileMessageCallback;
[scriptable, uuid(1e602d20-d066-4399-8997-daf36b3158ef)]
interface nsIRILDataCallInfo : nsISupports
@ -59,7 +59,7 @@ interface nsIVoicemailInfo : nsISupports
readonly attribute DOMString displayName;
};
[scriptable, uuid(2f1c8055-322e-490a-b1e1-4ccd5d546b3c)]
[scriptable, uuid(95e1be50-c912-11e2-8b8b-0800200c9a66)]
interface nsIRilContext : nsISupports
{
readonly attribute DOMString radioState;
@ -72,7 +72,7 @@ interface nsIRilContext : nsISupports
readonly attribute DOMString networkSelectionMode;
readonly attribute nsIDOMMozMobileICCInfo iccInfo;
readonly attribute nsIDOMMozIccInfo iccInfo;
readonly attribute nsIDOMMozMobileConnectionInfo voice;