Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 15253453 authored by Irfan Sheriff's avatar Irfan Sheriff Committed by Android Git Automerger
Browse files

am 79dc154a: Merge "Disable poor network avoidance by default" into jb-mr1-dev

* commit '79dc154a':
  Disable poor network avoidance by default
parents d44525dc 79dc154a
Loading
Loading
Loading
Loading
+8 −9
Original line number Diff line number Diff line
@@ -345,13 +345,6 @@ public class WifiWatchdogStateMachine extends StateMachine {
        // watchdog in an enabled state
        putSettingsGlobalBoolean(contentResolver, Settings.Global.WIFI_WATCHDOG_ON, true);

        // disable poor network avoidance
        if (sWifiOnly) {
            logd("Disabling poor network avoidance for wi-fi only device");
            putSettingsGlobalBoolean(contentResolver,
                    Settings.Global.WIFI_WATCHDOG_POOR_NETWORK_TEST_ENABLED, false);
        }

        WifiWatchdogStateMachine wwsm = new WifiWatchdogStateMachine(context);
        wwsm.start();
        return wwsm;
@@ -441,8 +434,14 @@ public class WifiWatchdogStateMachine extends StateMachine {
    private void updateSettings() {
        if (DBG) logd("Updating secure settings");

        // disable poor network avoidance
        if (sWifiOnly) {
            logd("Disabling poor network avoidance for wi-fi only device");
            mPoorNetworkDetectionEnabled = false;
        } else {
            mPoorNetworkDetectionEnabled = getSettingsGlobalBoolean(mContentResolver,
                Settings.Global.WIFI_WATCHDOG_POOR_NETWORK_TEST_ENABLED, true);
                    Settings.Global.WIFI_WATCHDOG_POOR_NETWORK_TEST_ENABLED, false);
        }
    }

    /**