Loading media/java/android/media/AudioAttributes.java +45 −40 Original line number Diff line number Diff line Loading @@ -816,6 +816,8 @@ public final class AudioAttributes implements Parcelable { */ @UnsupportedAppUsage public Builder setInternalLegacyStreamType(int streamType) { mContentType = CONTENT_TYPE_UNKNOWN; mUsage = USAGE_UNKNOWN; if (AudioProductStrategy.getAudioProductStrategies().size() > 0) { AudioAttributes attributes = AudioProductStrategy.getAudioAttributesForStrategyWithLegacyStreamType( Loading @@ -828,9 +830,9 @@ public final class AudioAttributes implements Parcelable { mTags = attributes.mTags; mBundle = attributes.mBundle; mSource = attributes.mSource; return this; } } if (mContentType == CONTENT_TYPE_UNKNOWN) { switch (streamType) { case AudioSystem.STREAM_VOICE_CALL: mContentType = CONTENT_TYPE_SPEECH; Loading Loading @@ -870,7 +872,10 @@ public final class AudioAttributes implements Parcelable { default: Log.e(TAG, "Invalid stream type " + streamType + " for AudioAttributes"); } } if (mUsage == USAGE_UNKNOWN) { mUsage = usageForStreamType(streamType); } return this; } Loading Loading
media/java/android/media/AudioAttributes.java +45 −40 Original line number Diff line number Diff line Loading @@ -816,6 +816,8 @@ public final class AudioAttributes implements Parcelable { */ @UnsupportedAppUsage public Builder setInternalLegacyStreamType(int streamType) { mContentType = CONTENT_TYPE_UNKNOWN; mUsage = USAGE_UNKNOWN; if (AudioProductStrategy.getAudioProductStrategies().size() > 0) { AudioAttributes attributes = AudioProductStrategy.getAudioAttributesForStrategyWithLegacyStreamType( Loading @@ -828,9 +830,9 @@ public final class AudioAttributes implements Parcelable { mTags = attributes.mTags; mBundle = attributes.mBundle; mSource = attributes.mSource; return this; } } if (mContentType == CONTENT_TYPE_UNKNOWN) { switch (streamType) { case AudioSystem.STREAM_VOICE_CALL: mContentType = CONTENT_TYPE_SPEECH; Loading Loading @@ -870,7 +872,10 @@ public final class AudioAttributes implements Parcelable { default: Log.e(TAG, "Invalid stream type " + streamType + " for AudioAttributes"); } } if (mUsage == USAGE_UNKNOWN) { mUsage = usageForStreamType(streamType); } return this; } Loading