diff options
author | Irfan Sheriff <isheriff@google.com> | 2010-01-25 19:10:31 -0800 |
---|---|---|
committer | Irfan Sheriff <isheriff@google.com> | 2010-01-25 19:10:31 -0800 |
commit | c30ffda0d84e0c3d9b8a4ccc18b3895ae467ae40 (patch) | |
tree | c25da79b6067d36a866c902765450647cb49275d /telephony | |
parent | 199566045d2c22981604b1894e416373eb0e74ed (diff) | |
parent | d051434773769926671bc6f98e273e385819b653 (diff) | |
download | frameworks_base-c30ffda0d84e0c3d9b8a4ccc18b3895ae467ae40.zip frameworks_base-c30ffda0d84e0c3d9b8a4ccc18b3895ae467ae40.tar.gz frameworks_base-c30ffda0d84e0c3d9b8a4ccc18b3895ae467ae40.tar.bz2 |
resolved conflicts for merge of d0514347 to master
Diffstat (limited to 'telephony')
-rw-r--r-- | telephony/java/com/android/internal/telephony/MccTable.java | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/telephony/java/com/android/internal/telephony/MccTable.java b/telephony/java/com/android/internal/telephony/MccTable.java index e25eb7b..7f62169 100644 --- a/telephony/java/com/android/internal/telephony/MccTable.java +++ b/telephony/java/com/android/internal/telephony/MccTable.java @@ -590,7 +590,7 @@ public final class MccTable if (mcc != 0) { setTimezoneFromMccIfNeeded(phone, mcc); setLocaleFromMccIfNeeded(phone, mcc); - setWifiChannelsFromMccIfNeeded(phone, mcc); + setWifiChannelsFromMcc(phone, mcc); } try { Configuration config = ActivityManagerNative.getDefault().getConfiguration(); @@ -646,20 +646,14 @@ public final class MccTable * @param phone PhoneBase to act on (get context from). * @param mcc Mobile Country Code of the SIM or SIM-like entity (build prop on CDMA) */ - private static void setWifiChannelsFromMccIfNeeded(PhoneBase phone, int mcc) { + private static void setWifiChannelsFromMcc(PhoneBase phone, int mcc) { int wifiChannels = MccTable.wifiChannelsForMcc(mcc); if (wifiChannels != 0) { Context context = phone.getContext(); - // only set to this default if the user hasn't manually set it - try { - Settings.Secure.getInt(context.getContentResolver(), - Settings.Secure.WIFI_NUM_ALLOWED_CHANNELS); - } catch (Settings.SettingNotFoundException e) { - Log.d(LOG_TAG, "WIFI_NUM_ALLOWED_CHANNESL set to " + wifiChannels); - WifiManager wM = (WifiManager) context.getSystemService(Context.WIFI_SERVICE); - // don't persist - wM.setNumAllowedChannels(wifiChannels, false); - } + Log.d(LOG_TAG, "WIFI_NUM_ALLOWED_CHANNELS set to " + wifiChannels); + WifiManager wM = (WifiManager) context.getSystemService(Context.WIFI_SERVICE); + //persist + wM.setNumAllowedChannels(wifiChannels, true); } } } |