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

Commit e35bde52 authored by Jean-Michel Trivi's avatar Jean-Michel Trivi Committed by Android (Google) Code Review
Browse files

Merge "Dynamic audio policies: fix AttributeMatchCriterion addition in mix"

parents 6ce4a46a fee832a0
Loading
Loading
Loading
Loading
+11 −2
Original line number Diff line number Diff line
@@ -428,8 +428,17 @@ public class AudioMixingRule {
                    }
                }
                // rule didn't exist, add it
                // FIXME doesn't work with RULE_MATCH_UID yet
                switch (match_rule) {
                    case RULE_MATCH_ATTRIBUTE_USAGE:
                    case RULE_MATCH_ATTRIBUTE_CAPTURE_PRESET:
                        mCriteria.add(new AttributeMatchCriterion(attrToMatch, rule));
                        break;
                    case RULE_MATCH_UID:
                        mCriteria.add(new AttributeMatchCriterion(intProp, rule));
                        break;
                    default:
                        throw new IllegalStateException("Unreachable code in addRuleInternal()");
                }
            }
            return this;
        }