Home
last modified time | relevance | path

Searched refs:FocusEntry (Results 1 – 5 of 5) sorted by relevance

/packages/services/Car/service/src/com/android/car/audio/
DCarAudioFocus.java111 private final ArrayMap<String, FocusEntry> mFocusHolders = new ArrayMap<>();
113 private final ArrayMap<String, FocusEntry> mFocusLosers = new ArrayMap<>();
173 private void abandonNonCriticalEntriesLocked(Map<String, FocusEntry> entries) { in abandonNonCriticalEntriesLocked()
175 for (FocusEntry holderEntry : entries.values()) { in abandonNonCriticalEntriesLocked()
190 FocusEntry removedEntry = entries.remove(clientId); in abandonNonCriticalEntriesLocked()
284 ArrayList<FocusEntry> permanentlyLost = new ArrayList<>(); in evaluateFocusRequestLocked()
285 FocusEntry replacedCurrentEntry = null; in evaluateFocusRequestLocked()
288 FocusEntry entry = mFocusHolders.valueAt(index); in evaluateFocusRequestLocked()
329 FocusEntry entry = mFocusLosers.valueAt(index); in evaluateFocusRequestLocked()
388 FocusEntry newEntry = new FocusEntry(focusEntry.getAudioFocusInfo(), in evaluateFocusRequestLocked()
[all …]
DFocusEntry.java38 final class FocusEntry { class
42 private final List<FocusEntry> mBlockers;
46 FocusEntry(@NonNull AudioFocusInfo audioFocusInfo, @AudioContext int context, in FocusEntry() method in FocusEntry
69 void addBlocker(FocusEntry blocker) { in addBlocker()
73 void removeBlocker(FocusEntry blocker) { in removeBlocker()
DFocusInteraction.java394 int evaluateRequest(int requestedUsage, FocusEntry focusHolder, boolean allowDucking, in evaluateRequest()
395 boolean allowsDelayedFocus, List<FocusEntry> focusLosers) { in evaluateRequest()
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/audio/
DFocusInteractionTest.java88 private final List<FocusEntry> mLosers = new ArrayList<>();
174 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_VIRTUAL_SOURCE); in evaluateResult_forRejectPair_returnsFailed()
189 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_VOICE_COMMUNICATION); in evaluateResult_forCallAndNavigation_withNavigationNotRejected_returnsConcurrent()
204 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_VOICE_COMMUNICATION); in evaluateResult_forCallAndNavigation_withNavigationRejected_returnsConcurrent()
216 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_VIRTUAL_SOURCE); in evaluateResult_forRejectPair_doesNotAddToLosers()
226 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_MEDIA); in evaluateRequest_forExclusivePair_returnsGranted()
237 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_MEDIA); in evaluateRequest_forExclusivePair_addsEntryToLosers()
248 FocusEntry focusEntry = newMockFocusEntryWithUsage(USAGE_ASSISTANCE_NAVIGATION_GUIDANCE); in evaluateResult_forConcurrentPair_returnsGranted()
259 FocusEntry focusEntry = in evaluateResult_forConcurrentPair_andNoDucking_addsToLosers()
272 FocusEntry focusEntry = newMockFocusEntryWithDuckingBehavior( in evaluateResult_forConcurrentPair_andWantsPauseInsteadOfDucking_addsToLosers()
[all …]
DFocusEntryTest.java70 FocusEntry focusEntry = new FocusEntry(info, TEST_MEDIA_CONTEXT, mMockPM); in wantsPauseInsteadOfDucking_whenFlagIsSet_returnsTrue()
79 FocusEntry focusEntry = new FocusEntry(info, TEST_MEDIA_CONTEXT, mMockPM); in wantsPauseInsteadOfDucking_whenFlagIsNotSet_returnsFalse()
87 FocusEntry focusEntry = new FocusEntry(info, TEST_MEDIA_CONTEXT, mMockPM); in receivesDuckEvents_whenBundleDoesNotReceiveDuckingEvents_returnsFalse()
97 FocusEntry focusEntry = new FocusEntry(info, TEST_MEDIA_CONTEXT, mMockPM); in receivesDuckEvents_withoutReceiveCarAudioDuckingEventsPermission_returnsFalse()
107 FocusEntry focusEntry = new FocusEntry(info, TEST_MEDIA_CONTEXT, mMockPM); in receivesDuckEvents_withReceiveCarAudioDuckingEventsPermission_returnsTrue()