按照MTK给的方案进行了修改,另外还加了一些字符串数组的修改:
--------------- apps/Settings/res/drawable/wifi_signal_lock.xml ---------------
index 2ad6d91..f7953d2 100644
@@ -15,9 +15,12 @@
-->
<level-list xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:maxLevel="0"
android:drawable="@drawable/ic_wifi_lock_signal_1" />
- <item android:maxLevel="1"
android:drawable="@drawable/ic_wifi_lock_signal_2" />
- <item android:maxLevel="2"
android:drawable="@drawable/ic_wifi_lock_signal_3" />
- <item android:maxLevel="3"
android:drawable="@drawable/ic_wifi_lock_signal_4" />
+ <!-- modify by BW_APP_zengdakui for bug(39969) .start-->
+ <item android:maxLevel="0"
android:drawable="@drawable/ic_wifi_lock_signal_0" />
+ <item android:maxLevel="1"
android:drawable="@drawable/ic_wifi_lock_signal_1" />
+ <item android:maxLevel="2"
android:drawable="@drawable/ic_wifi_lock_signal_2" />
+ <item android:maxLevel="3"
android:drawable="@drawable/ic_wifi_lock_signal_3" />
+ <item android:maxLevel="4"
android:drawable="@drawable/ic_wifi_lock_signal_4" />
+ <!-- modify by BW_APP_zengdakui for bug(39969) .end -->
</level-list>
--------------- apps/Settings/res/drawable/wifi_signal_open.xml ---------------
index b506dd3..44dfb9b 100644
@@ -15,9 +15,12 @@
-->
<level-list xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:maxLevel="0" android:drawable="@drawable/ic_wifi_signal_1"
/>
- <item android:maxLevel="1" android:drawable="@drawable/ic_wifi_signal_2"
/>
- <item android:maxLevel="2" android:drawable="@drawable/ic_wifi_signal_3"
/>
- <item android:maxLevel="3" android:drawable="@drawable/ic_wifi_signal_4"
/>
+ <!-- modify by BW_APP_zengdakui for bug(39969) .start -->
+ <item android:maxLevel="0" android:drawable="@drawable/ic_wifi_signal_0"
/>
+ <item android:maxLevel="1" android:drawable="@drawable/ic_wifi_signal_1"
/>
+ <item android:maxLevel="2" android:drawable="@drawable/ic_wifi_signal_2"
/>
+ <item android:maxLevel="3" android:drawable="@drawable/ic_wifi_signal_3"
/>
+ <item android:maxLevel="4" android:drawable="@drawable/ic_wifi_signal_4"
/>
+ <!-- modify by BW_APP_zengdakui for bug(39969) .end -->
</level-list>
------------------ apps/Settings/res/values-zh-rCN/arrays.xml
------------------
index 4f92ef6..19e6bb8 100644
@@ -122,12 +122,16 @@
<item msgid="477015974247590543">"1 小时"</item>
<item msgid="5198271470953124739">"永不超时"</item>
</string-array>
+
+ <!-- modify by BW_APP_zengdakui for bug(39969) .start -->
<string-array name="wifi_signal">
+ <item msgid="2245412278046491293">"极弱"</item>
<item msgid="2245412278046491293">"弱"</item>
<item msgid="5615082285463430971">"一般"</item>
<item msgid="3565079809875324621">"较强"</item>
<item msgid="5702329417707689835">"强"</item>
</string-array>
+ <!-- modify by BW_APP_zengdakui for bug(39969) .end -->
<string-array name="wifi_sleep_policy_entries">
<item msgid="3269131034472904310">"始终"</item>
<item msgid="844721238536786870">"仅限充电时"</item>
--------------------- apps/Settings/res/values/arrays.xml ---------------------
index bf83879..c0a5f08 100644
@@ -358,12 +358,15 @@
<!-- Match this with drawable.wifi_signal. --> <skip />
<!-- Wi-Fi settings. The signal strength a Wi-Fi network has. -->
+<!--modify by BW_APP_zengdakui for bug(39969) .start -->
<string-array name="wifi_signal">
+ <item>Poorest</item>
<item>Poor</item>
<item>Fair</item>
<item>Good</item>
<item>Excellent</item>
</string-array>
+<!--modify by BW_APP_zengdakui for bug(39969) .end -->
<!-- Wi-Fi settings. Presented as a list dialog to the user to choose the
Wi-Fi sleep policy. -->
<string-array name="wifi_sleep_policy_entries">
--------- apps/Settings/src/com/android/settings/wifi/AccessPoint.java
---------
index d30be9d..5ca64b0 100644
@@ -371,13 +371,16 @@ class AccessPoint extends Preference {
if (mRssi == Integer.MAX_VALUE) {
return -1;
}
+
+ //modify by BW_APP_zengdakui for bug(39969) .start
/**[Add/Comment] by BW_APP [wangyao] for [39862 wifi signal cts
failed.] --start*/
if (SystemProperties.getBoolean("ro.bw.show_huawei_wifi", false)) {
- return WifiManager.calculateSignalLevelCustom(mRssi, 4);
+ return WifiManager.calculateSignalLevelCustom(mRssi, 5);
} else {
- return WifiManager.calculateSignalLevel(mRssi, 4);
+ return WifiManager.calculateSignalLevel(mRssi, 5);
}
/**[Add/Comment] by BW_APP [wangyao] for [39862 wifi signal cts
failed.] --end*/
+ //modify by BW_APP_zengdakui for bug(39969) .end
}
WifiConfiguration getConfig() {
-------- apps/Settings/src/com/android/settings/wifi/WifiSettings.java --------
index c668a1c..2813aed 100644
@@ -1111,6 +1111,9 @@ public class WifiSettings extends
SettingsPreferenceFragment
}
} else if (WifiManager.RSSI_CHANGED_ACTION.equals(action)) {
updateConnectionState(null);
+ //modify by BW_APP_zengdakui for bug(39969) .start
+ updateAccessPoints();
+ //modify by BW_APP_zengdakui for bug(39969) .end
} else if (WifiManager.NO_CERTIFICATION_ACTION.equals(action)) {
/// M: show error message @{
String apSSID = "";
------- apps/Settings/src/com/android/settings/wifi/p2p/WifiP2pPeer.java
-------
index d05c9a3..eb169ee 100644
@@ -39,8 +39,9 @@ public class WifiP2pPeer extends Preference {
private int mRssi;
private ImageView mSignal;
-
- private static final int SIGNAL_LEVELS = 4;
+//modify by BW_APP_zengdakui for bug(39969) .start
+ private static final int SIGNAL_LEVELS = 5;
+//modify by BW_APP_zengdakui for bug(39969) .end
public WifiP2pPeer(Context context, WifiP2pDevice dev) {
super(context);
WIFI 状态栏显示的wifi信号强度与wifisetting列表不一致
原文地址:http://blog.csdn.net/eoeandroida/article/details/38040759