Merge donut into master
This commit is contained in:
@@ -44,8 +44,11 @@ public class DriverCall implements Comparable {
|
||||
public String number;
|
||||
public int TOA;
|
||||
public boolean isVoice;
|
||||
public boolean isVoicePrivacy;
|
||||
public int als;
|
||||
public int numberPresentation;
|
||||
public String name;
|
||||
public int namePresentation;
|
||||
|
||||
/** returns null on error */
|
||||
static DriverCall
|
||||
@@ -101,11 +104,15 @@ public class DriverCall implements Comparable {
|
||||
public String
|
||||
toString() {
|
||||
return "id=" + index + ","
|
||||
+ (isMT ? "mt" : "mo") + ","
|
||||
+ state + ","
|
||||
+ (isVoice ? "voice" : "no_voc") + ","
|
||||
+ "toa=" + TOA + ","
|
||||
+ (isMpty ? "conf" : "norm") + ","
|
||||
+ TOA + "," + als + ",cli " + numberPresentation;
|
||||
+ (isMT ? "mt" : "mo") + ","
|
||||
+ als + ","
|
||||
+ (isVoice ? "voc" : "nonvoc") + ","
|
||||
+ (isVoicePrivacy ? "evp" : "noevp") + ","
|
||||
/*+ "number=" + number */ + ",cli=" + numberPresentation + ","
|
||||
/*+ "name="+ name */ + "," + namePresentation;
|
||||
}
|
||||
|
||||
public static State
|
||||
|
||||
@@ -2625,8 +2625,16 @@ public final class RIL extends BaseCommands implements CommandsInterface {
|
||||
dc.als = p.readInt();
|
||||
voiceSettings = p.readInt();
|
||||
dc.isVoice = (0 == voiceSettings) ? false : true;
|
||||
|
||||
//dc.isVoicePrivacy = (0 != p.readInt());
|
||||
int voicePrivacy = p.readInt();
|
||||
dc.isVoicePrivacy = (0 != voicePrivacy);
|
||||
|
||||
dc.number = p.readString();
|
||||
dc.numberPresentation = DriverCall.presentationFromCLIP(p.readInt());
|
||||
int np = p.readInt();
|
||||
dc.numberPresentation = DriverCall.presentationFromCLIP(np);
|
||||
dc.name = p.readString();
|
||||
dc.namePresentation = p.readInt();
|
||||
|
||||
// Make sure there's a leading + on addresses with a TOA
|
||||
// of 145
|
||||
@@ -2664,7 +2672,7 @@ public final class RIL extends BaseCommands implements CommandsInterface {
|
||||
PDPContextState pdp = new PDPContextState();
|
||||
|
||||
pdp.cid = p.readInt();
|
||||
pdp.active = p.readInt() == 0 ? false : true;
|
||||
pdp.active = p.readInt();
|
||||
pdp.type = p.readString();
|
||||
pdp.apn = p.readString();
|
||||
pdp.address = p.readString();
|
||||
|
||||
@@ -485,13 +485,17 @@ final class CdmaServiceStateTracker extends ServiceStateTracker {
|
||||
-1, //[3] baseStationLongitude
|
||||
0, //[4] cssIndicator; init with 0, because it is treated as a boolean
|
||||
-1, //[5] systemId
|
||||
-1 //[6] networkId
|
||||
-1, //[6] networkId
|
||||
-1, //[7] TSB-58 Roaming indicator // NEWRIL:TODO UNUSED
|
||||
-1, //[8] Indicates if current system is in PRL // NEWRIL:TODO UNUSED
|
||||
-1, //[9] Is default roaming indicator from PRL // NEWRIL:TODO UNUSED
|
||||
-1, //[10] If registration state is 3 this is reason for denial // NEWRIL:TODO UNUSED
|
||||
};
|
||||
|
||||
if (states.length > 0) {
|
||||
try {
|
||||
this.mRegistrationState = Integer.parseInt(states[0]);
|
||||
if (states.length == 10) {
|
||||
if (states.length >= 10) {
|
||||
for(int i = 0; i < states.length - offset; i++) {
|
||||
if (states[i + offset] != null
|
||||
&& states[i + offset].length() > 0) {
|
||||
@@ -536,7 +540,7 @@ final class CdmaServiceStateTracker extends ServiceStateTracker {
|
||||
case EVENT_POLL_STATE_OPERATOR_CDMA:
|
||||
String opNames[] = (String[])ar.result;
|
||||
|
||||
if (opNames != null && opNames.length >= 4) {
|
||||
if (opNames != null && opNames.length >= 3) {
|
||||
newSS.setOperatorName (opNames[0], opNames[1], opNames[2]);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -53,6 +53,7 @@ public final class RuimRecords extends IccRecords {
|
||||
String mdn = null; // My mobile number
|
||||
String h_sid;
|
||||
String h_nid;
|
||||
String min2_min1; // 10 digit MIN value MIN2+MIN1 NEWRIL:TODO currently unused
|
||||
|
||||
// is not initialized
|
||||
|
||||
@@ -214,6 +215,9 @@ public final class RuimRecords extends IccRecords {
|
||||
mdn = localTemp[0];
|
||||
h_sid = localTemp[1];
|
||||
h_nid = localTemp[2];
|
||||
if (localTemp.length >= 3) { // NEWRIL:TODO remove when new ril always returns min2_min1
|
||||
min2_min1 = localTemp[3];
|
||||
}
|
||||
|
||||
Log.d(LOG_TAG, "MDN: " + mdn);
|
||||
|
||||
|
||||
@@ -790,7 +790,7 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
|
||||
private boolean
|
||||
pdpStatesHasActiveCID (ArrayList<PDPContextState> states, int cid) {
|
||||
for (int i = 0, s = states.size() ; i < s ; i++) {
|
||||
if (states.get(i).cid == cid) return states.get(i).active;
|
||||
if (states.get(i).cid == cid) return (states.get(i).active != 0);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
@@ -21,7 +21,7 @@ package com.android.internal.telephony.gsm;
|
||||
*/
|
||||
public class PDPContextState {
|
||||
public int cid;
|
||||
public boolean active;
|
||||
public int active;
|
||||
public String type;
|
||||
public String apn;
|
||||
public String address;
|
||||
|
||||
@@ -832,22 +832,30 @@ public final class SimulatedCommands extends BaseCommands
|
||||
}
|
||||
|
||||
/**
|
||||
* response.obj.result is an String[3]
|
||||
* response.obj.result[0] is registration state 0-5 from TS 27.007 7.2
|
||||
* response.obj.result[1] is LAC if registered or NULL if not
|
||||
* response.obj.result[2] is CID if registered or NULL if not
|
||||
* valid LAC are 0x0000 - 0xffff
|
||||
* valid CID are 0x00000000 - 0xffffffff
|
||||
* response.obj.result is an String[14]
|
||||
* See ril.h for details
|
||||
*
|
||||
* Please note that registration state 4 ("unknown") is treated
|
||||
* as "out of service" above
|
||||
*/
|
||||
public void getRegistrationState (Message result) {
|
||||
String ret[] = new String[3];
|
||||
String ret[] = new String[14];
|
||||
|
||||
ret[0] = "5"; // registered roam
|
||||
ret[1] = null;
|
||||
ret[2] = null;
|
||||
ret[3] = null;
|
||||
ret[4] = null;
|
||||
ret[5] = null;
|
||||
ret[6] = null;
|
||||
ret[7] = null;
|
||||
ret[8] = null;
|
||||
ret[9] = null;
|
||||
ret[10] = null;
|
||||
ret[11] = null;
|
||||
ret[12] = null;
|
||||
ret[13] = null;
|
||||
ret[14] = null;
|
||||
|
||||
resultSuccess(result, ret);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user