зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1033142 - Part 1: read EF_GID1 from (u)sim card. r=hsinyi
This commit is contained in:
Родитель
ad0c6d62ec
Коммит
907dc59d82
|
@ -502,6 +502,7 @@ this.ICC_EF_UST = 0x6f38; // For USIM
|
|||
this.ICC_EF_ADN = 0x6f3a;
|
||||
this.ICC_EF_FDN = 0x6f3b;
|
||||
this.ICC_EF_SMS = 0x6f3c;
|
||||
this.ICC_EF_GID1 = 0x6f3e;
|
||||
this.ICC_EF_MSISDN = 0x6f40;
|
||||
this.ICC_EF_CBMI = 0x6f45;
|
||||
this.ICC_EF_SPN = 0x6f46;
|
||||
|
@ -1232,6 +1233,7 @@ this.GECKO_ICC_SERVICES = {
|
|||
PLMNSEL: 7,
|
||||
MSISDN: 9,
|
||||
CBMI: 14,
|
||||
GID1: 15,
|
||||
SPN: 17,
|
||||
SDN: 18,
|
||||
DATA_DOWNLOAD_SMS_CB: 25,
|
||||
|
@ -1250,6 +1252,7 @@ this.GECKO_ICC_SERVICES = {
|
|||
BDN: 6,
|
||||
CBMI: 15,
|
||||
CBMIR: 16,
|
||||
GID1: 17,
|
||||
SPN: 19,
|
||||
MSISDN: 21,
|
||||
DATA_DOWNLOAD_SMS_PP: 28,
|
||||
|
|
|
@ -11862,6 +11862,7 @@ ICCFileHelperObject.prototype = {
|
|||
case ICC_EF_CBMIR:
|
||||
case ICC_EF_OPL:
|
||||
case ICC_EF_PNN:
|
||||
case ICC_EF_GID1:
|
||||
return EF_PATH_MF_SIM + EF_PATH_DF_GSM;
|
||||
default:
|
||||
return null;
|
||||
|
@ -11887,6 +11888,7 @@ ICCFileHelperObject.prototype = {
|
|||
case ICC_EF_OPL:
|
||||
case ICC_EF_PNN:
|
||||
case ICC_EF_SMS:
|
||||
case ICC_EF_GID1:
|
||||
return EF_PATH_MF_SIM + EF_PATH_ADF_USIM;
|
||||
default:
|
||||
// The file ids in USIM phone book entries are decided by the
|
||||
|
@ -13031,6 +13033,13 @@ SimRecordHelperObject.prototype = {
|
|||
if (DEBUG) this.context.debug("OPL: OPL is not available");
|
||||
}
|
||||
|
||||
if (ICCUtilsHelper.isICCServiceAvailable("GID1")) {
|
||||
if (DEBUG) this.context.debug("GID1: GID1 is available");
|
||||
this.readGID1();
|
||||
} else {
|
||||
if (DEBUG) this.context.debug("GID1: GID1 is not available");
|
||||
}
|
||||
|
||||
if (ICCUtilsHelper.isICCServiceAvailable("CBMI")) {
|
||||
this.readCBMI();
|
||||
} else {
|
||||
|
@ -13622,6 +13631,23 @@ SimRecordHelperObject.prototype = {
|
|||
onerror: onerror
|
||||
});
|
||||
},
|
||||
|
||||
readGID1: function() {
|
||||
function callback() {
|
||||
let Buf = this.context.Buf;
|
||||
let RIL = this.context.RIL;
|
||||
|
||||
RIL.iccInfoPrivate.gid1 = Buf.readString();
|
||||
if (DEBUG) {
|
||||
this.context.debug("GID1: " + RIL.iccInfoPrivate.gid1);
|
||||
}
|
||||
}
|
||||
|
||||
this.context.ICCIOHelper.loadTransparentEF({
|
||||
fileId: ICC_EF_GID1,
|
||||
callback: callback.bind(this)
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
function RuimRecordHelperObject(aContext) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче