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

Commit a9b4f094 authored by jiabin's avatar jiabin
Browse files

Copy flags except MUTE_HAPTIC in setLegacyStreamType.

FLAG_MUTE_HAPTIC will be set in AudioAttributes.mFlags. But it should
only be controlled by mMuteHapticChannels in AudioAttributes.Builder.
When copying flags in AudioAttributes.Builder, FLAG_MUTE_HAPTIC should
be ignored.

Bug: 138807243
Test: run SoundPoolHapticTest
Change-Id: I21395399746353b947355b89e5dbd379f42f5d20
parent e1c38e1a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -824,7 +824,7 @@ public final class AudioAttributes implements Parcelable {
                if (attributes != null) {
                    mUsage = attributes.mUsage;
                    mContentType = attributes.mContentType;
                    mFlags = attributes.mFlags;
                    mFlags = attributes.getAllFlags();
                    mMuteHapticChannels = attributes.areHapticChannelsMuted();
                    mTags = attributes.mTags;
                    mBundle = attributes.mBundle;