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

Commit cfe67aa5 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Make back mic available when getting all available mic." into pi-dev

parents 912853be 9697c6c5
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -21963,6 +21963,7 @@ package android.media {
  }
  public final class AudioDeviceInfo {
    method public java.lang.String getAddress();
    method public int[] getChannelCounts();
    method public int[] getChannelIndexMasks();
    method public int[] getChannelMasks();
@@ -24454,6 +24455,7 @@ package android.media {
  }
  public final class MicrophoneInfo {
    method public java.lang.String getAddress();
    method public java.util.List<android.util.Pair<java.lang.Integer, java.lang.Integer>> getChannelMapping();
    method public java.lang.String getDescription();
    method public int getDirectionality();
+1 −2
Original line number Diff line number Diff line
@@ -226,11 +226,10 @@ public final class AudioDeviceInfo {
    }

    /**
     * @hide
     * @return The "address" string of the device. This generally contains device-specific
     * parameters.
     */
    public String getAddress() {
    public @NonNull String getAddress() {
        return mPort.address();
    }

+1 −2
Original line number Diff line number Diff line
@@ -4596,8 +4596,7 @@ public class AudioManager {

    private static boolean checkTypes(AudioDevicePort port) {
        return AudioDeviceInfo.convertInternalDeviceToDeviceType(port.type()) !=
                    AudioDeviceInfo.TYPE_UNKNOWN &&
                port.type() != AudioSystem.DEVICE_IN_BACK_MIC;
                    AudioDeviceInfo.TYPE_UNKNOWN;
    }

    /**
+2 −2
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
package android.media;

import android.annotation.IntDef;
import android.annotation.NonNull;
import android.util.Pair;

import java.lang.annotation.Retention;
@@ -224,12 +225,11 @@ public final class MicrophoneInfo {
    }

    /**
     * @hide
     * Returns The "address" string of the microphone that corresponds to the
     * address returned by {@link AudioDeviceInfo#getAddress()}
     * @return the address of the microphone
     */
    public String getAddress() {
    public @NonNull String getAddress() {
        return mAddress;
    }