diff options
author | Robert Greenwalt <robdroid@android.com> | 2009-08-13 15:59:51 -0700 |
---|---|---|
committer | Robert Greenwalt <robdroid@android.com> | 2009-08-17 15:20:14 -0700 |
commit | 25a5d3db3ff06b9952395832308bc3b48913c4ee (patch) | |
tree | 64f9afb592b5653f515867bdbcf952e9e0090c56 /core | |
parent | 60fae2af3c526c52728f8e303c5374c4e5c8c83b (diff) | |
download | frameworks_base-25a5d3db3ff06b9952395832308bc3b48913c4ee.zip frameworks_base-25a5d3db3ff06b9952395832308bc3b48913c4ee.tar.gz frameworks_base-25a5d3db3ff06b9952395832308bc3b48913c4ee.tar.bz2 |
Fix CDMA to startup/shutdown based on apn en/disab
Fixes MMS during wifi.
Also fixes CDMA for ConnectivityManager change.
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/net/MobileDataStateTracker.java | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/core/java/android/net/MobileDataStateTracker.java b/core/java/android/net/MobileDataStateTracker.java index 6b00900..da1115d 100644 --- a/core/java/android/net/MobileDataStateTracker.java +++ b/core/java/android/net/MobileDataStateTracker.java @@ -49,7 +49,6 @@ public class MobileDataStateTracker extends NetworkStateTracker { private String mApnType; private boolean mEnabled; - private boolean mTeardownRequested; /** * Create a new MobileDataStateTracker @@ -66,7 +65,6 @@ public class MobileDataStateTracker extends NetworkStateTracker { TelephonyManager.getDefault().getNetworkTypeName()); mApnType = apnType; mPhoneService = null; - mTeardownRequested = false; if(netType == ConnectivityManager.TYPE_MOBILE) { mEnabled = true; } else { @@ -81,7 +79,9 @@ public class MobileDataStateTracker extends NetworkStateTracker { "net.eth0.dns3", "net.eth0.dns4", "net.gprs.dns1", - "net.gprs.dns2"}; + "net.gprs.dns2", + "net.ppp0.dns1", + "net.ppp0.dns2"}; } @@ -160,9 +160,9 @@ public class MobileDataStateTracker extends NetworkStateTracker { switch (state) { case DISCONNECTED: - if(mTeardownRequested) { + if(isTeardownRequested()) { mEnabled = false; - mTeardownRequested = false; + setTeardownRequested(false); } setDetailedState(DetailedState.DISCONNECTED, reason, apnName); @@ -277,7 +277,7 @@ public class MobileDataStateTracker extends NetworkStateTracker { */ @Override public boolean teardown() { - mTeardownRequested = true; + setTeardownRequested(true); return (setEnableApn(mApnType, false) != Phone.APN_REQUEST_FAILED); } @@ -286,7 +286,7 @@ public class MobileDataStateTracker extends NetworkStateTracker { */ public boolean reconnect() { mEnabled = true; - mTeardownRequested = false; + setTeardownRequested(false); mEnabled = (setEnableApn(mApnType, true) != Phone.APN_REQUEST_FAILED); return mEnabled; |