Settings: Use new API for setting wifi scan always on

Bug: 148514485
Test: Manually verified the toggle from Settings
Test: m RunSettingsRoboTests -j ROBOTEST_FILTER=com.android.settings.wifi
Change-Id: I0a55b7212c97c11d50b0a05eec743e8ebe9ea6d8
This commit is contained in:
Roshan Pius
2020-02-12 14:17:49 -08:00
parent a023de72a9
commit a7e96dd80e
13 changed files with 66 additions and 67 deletions

View File

@@ -153,8 +153,7 @@ public class WifiWakeupPreferenceController extends TogglePreferenceController i
}
private boolean getWifiScanningEnabled() {
return Settings.Global.getInt(mContext.getContentResolver(),
Settings.Global.WIFI_SCAN_ALWAYS_AVAILABLE, 0) == 1;
return mWifiManager.isScanAlwaysAvailable();
}
private void showScanningDialog() {