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

Commit 7b72c393 authored by Nathalie Le Clair's avatar Nathalie Le Clair
Browse files

Allow for internal types in @hide API

Bug: 227425913
Test: manual
Change-Id: I5fe2e262a4be6412f7f67b55ccdba0a867951f14
parent 3336a902
Loading
Loading
Loading
Loading
+2 −8
Original line number Diff line number Diff line
@@ -5898,14 +5898,8 @@ public class AudioManager {
     */
    @UnsupportedAppUsage
    @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING)
    public void setWiredDeviceConnectionState(int device, int state, String address,
            String name) {
        final IAudioService service = getService();
        int role = isOutputDevice(device)
                ? AudioDeviceAttributes.ROLE_OUTPUT : AudioDeviceAttributes.ROLE_INPUT;
        AudioDeviceAttributes attributes = new AudioDeviceAttributes(
                role, AudioDeviceInfo.convertInternalDeviceToDeviceType(device), address,
                name, new ArrayList<>()/*mAudioProfiles*/, new ArrayList<>()/*mAudioDescriptors*/);
    public void setWiredDeviceConnectionState(int device, int state, String address, String name) {
        AudioDeviceAttributes attributes = new AudioDeviceAttributes(device, address, name);
        setWiredDeviceConnectionState(attributes, state);
    }