summaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorJaikumar Ganesh <jaikumar@google.com>2009-05-14 22:26:35 -0700
committerJaikumar Ganesh <jaikumar@google.com>2009-05-19 17:29:42 -0700
commitee748d37b01b3affb72b701d95ba20c189887b5f (patch)
treef097d1562c8b121607503e0f0176bd63102e30c6 /telephony
parent83a6ec600259d245b799a99a8e963704db031a63 (diff)
downloadframeworks_base-ee748d37b01b3affb72b701d95ba20c189887b5f.zip
frameworks_base-ee748d37b01b3affb72b701d95ba20c189887b5f.tar.gz
frameworks_base-ee748d37b01b3affb72b701d95ba20c189887b5f.tar.bz2
Fix network preference getting incorrectly set.
When the phone process crashes, we set the network preference incorrectly. Also read the default value from a system property.
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/com/android/internal/telephony/Phone.java24
-rw-r--r--telephony/java/com/android/internal/telephony/RIL.java2
2 files changed, 13 insertions, 13 deletions
diff --git a/telephony/java/com/android/internal/telephony/Phone.java b/telephony/java/com/android/internal/telephony/Phone.java
index b5f2afe..4d0cf41 100644
--- a/telephony/java/com/android/internal/telephony/Phone.java
+++ b/telephony/java/com/android/internal/telephony/Phone.java
@@ -165,18 +165,18 @@ public interface Phone {
// Used for preferred network type
// Note NT_* substitute RILConstants.NETWORK_MODE_* above the Phone
- static final int NT_MODE_WCDMA_PREF = 0; /* GSM/WCDMA (WCDMA preferred) */
- static final int NT_MODE_GSM_ONLY = 1; /* GSM only */
- static final int NT_MODE_WCDMA_ONLY = 2; /* WCDMA only */
- static final int NT_MODE_GSM_UMTS = 3; /* GSM/WCDMA (auto mode, according to PRL)
- AVAILABLE Application Settings menu */
- static final int NT_MODE_CDMA = 4; /* CDMA and EvDo (auto mode, according to PRL)
- AVAILABLE Application Settings menu */
- static final int NT_MODE_CDMA_NO_EVDO = 5; /* CDMA only */
- static final int NT_MODE_EVDO_NO_CDMA = 6; /* EvDo only */
- static final int NT_MODE_GLOBAL = 7; /* GSM/WCDMA, CDMA, and EvDo (auto mode, according
- to PRL) AVAILABLE Application Settings menu */
- static final int PREFERRED_NT_MODE = NT_MODE_GLOBAL;
+ int NT_MODE_WCDMA_PREF = RILConstants.NETWORK_MODE_WCDMA_PREF;
+ int NT_MODE_GSM_ONLY = RILConstants.NETWORK_MODE_GSM_ONLY;
+ int NT_MODE_WCDMA_ONLY = RILConstants.NETWORK_MODE_WCDMA_ONLY;
+ int NT_MODE_GSM_UMTS = RILConstants.NETWORK_MODE_GSM_UMTS;
+
+ int NT_MODE_CDMA = RILConstants.NETWORK_MODE_CDMA;
+
+ int NT_MODE_CDMA_NO_EVDO = RILConstants.NETWORK_MODE_CDMA_NO_EVDO;
+ int NT_MODE_EVDO_NO_CDMA = RILConstants.NETWORK_MODE_EVDO_NO_CDMA;
+ int NT_MODE_GLOBAL = RILConstants.NETWORK_MODE_GLOBAL;
+
+ int PREFERRED_NT_MODE = RILConstants.PREFERRED_NETWORK_MODE;
// Used for CDMA roaming mode
diff --git a/telephony/java/com/android/internal/telephony/RIL.java b/telephony/java/com/android/internal/telephony/RIL.java
index 04e33fe..070d233 100644
--- a/telephony/java/com/android/internal/telephony/RIL.java
+++ b/telephony/java/com/android/internal/telephony/RIL.java
@@ -1857,7 +1857,7 @@ public final class RIL extends BaseCommands implements CommandsInterface {
* and/or radio knowing.
*/
if (RILJ_LOGD) Log.d(LOG_TAG, "Radio ON @ init; reset to OFF");
- setRadioPower(false, null);
+ setRadioPower(false, null);
} else {
if (DBG) Log.d(LOG_TAG, "Radio OFF @ init");
setRadioState(newState);