Prevent brief flash of "Error" in hotspot status text

When toggling the master preference to turn on wifi hotspot, it briefly
changes the status text to "Error" because we have a catch-all in a
function monitoring wifi state changes for unexpected status codes, and
we weren't expecting to see the status of WIFI_AP_STATE_ENABLING before
the status of WIFI_AP_STATE_ENABLED.

Bug: 64811203
Test: make RunSettingsRoboTests
Change-Id: Ifba7abadbfba9ce93cc524b17232c65570f0f428
This commit is contained in:
Antony Sargent
2017-09-11 16:43:58 -07:00
parent adef5b23e0
commit a2559ab128
2 changed files with 32 additions and 12 deletions

View File

@@ -139,6 +139,7 @@ public class WifiTetherPreferenceController extends AbstractPreferenceController
private void handleWifiApStateChanged(int state, int reason) {
switch (state) {
case WifiManager.WIFI_AP_STATE_ENABLING:
case WifiManager.WIFI_AP_STATE_ENABLED:
/**
* Summary on enable is handled by tether