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

Commit e6edaa9e authored by Rebecca Silberstein's avatar Rebecca Silberstein
Browse files

WifiManager: deprecate and remove setWifiApEnabled

Officially deprecate and remove the setWifiApEnabled call.

Bug: 38436773
Test: frameworks/opt/net/wifi/tests/wifitests/runtests.sh
Test: frameworks/base/wifi/tests/runtests.sh
Test: cts-tradefed run cts-dev --mo CtsNetTestCases -t android.net.wifi.cts.WifiManagerTest
Change-Id: Ifefe0b186d074b49ab1cc94e1c166117f3d7bdf7
parent 62bf2b96
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -267,6 +267,14 @@ package android.net {

}

package android.net.wifi {

  public class WifiManager {
    method public deprecated boolean setWifiApEnabled(android.net.wifi.WifiConfiguration, boolean);
  }

}

package android.os {

  public class BatteryManager {
+1 −1
Original line number Diff line number Diff line
@@ -29184,7 +29184,7 @@ package android.net.wifi {
    method public void setTdlsEnabled(java.net.InetAddress, boolean);
    method public void setTdlsEnabledWithMacAddress(java.lang.String, boolean);
    method public boolean setWifiApConfiguration(android.net.wifi.WifiConfiguration);
    method public boolean setWifiApEnabled(android.net.wifi.WifiConfiguration, boolean);
    method public deprecated boolean setWifiApEnabled(android.net.wifi.WifiConfiguration, boolean);
    method public boolean setWifiEnabled(boolean);
    method public void startLocalOnlyHotspot(android.net.wifi.WifiManager.LocalOnlyHotspotCallback, android.os.Handler);
    method public deprecated boolean startLocationRestrictedScan(android.os.WorkSource);
+8 −0
Original line number Diff line number Diff line
@@ -267,6 +267,14 @@ package android.net {

}

package android.net.wifi {

  public class WifiManager {
    method public deprecated boolean setWifiApEnabled(android.net.wifi.WifiConfiguration, boolean);
  }

}

package android.os {

  public class BatteryManager {
+4 −1
Original line number Diff line number Diff line
@@ -1837,7 +1837,7 @@ public class WifiManager {
    }

    /**
     * This call will be deprecated and removed in an upcoming release.  It is no longer used to
     * This call is deprecated and removed.  It is no longer used to
     * start WiFi Tethering.  Please use {@link ConnectivityManager#startTethering(int, boolean,
     * ConnectivityManager#OnStartTetheringCallback)} if
     * the caller has proper permissions.  Callers can also use the LocalOnlyHotspot feature for a
@@ -1849,8 +1849,11 @@ public class WifiManager {
     * @return {@code false}
     *
     * @hide
     * @deprecated This API is nolonger supported.
     * @removed
     */
    @SystemApi
    @Deprecated
    @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED)
    public boolean setWifiApEnabled(WifiConfiguration wifiConfig, boolean enabled) {
        String packageName = mContext.getOpPackageName();