diff options
| author | 2023-01-20 14:22:15 +0100 | |
|---|---|---|
| committer | 2023-02-06 16:13:47 +0100 | |
| commit | 6f96eec9089de00a71d36d75b599b858f75fb6a8 (patch) | |
| tree | be0e75b4d795af6057ac41bd6d72fe24d91b0d47 /libs/androidfw/ApkParsing.cpp | |
| parent | c80109db1a017d3fa6699cc38f5114dcb14d7464 (diff) | |
Add adjust-only absolute volume behavior.
Adjust-only behavior (DEVICE_VOLUME_BEHAVIOR_ABSOLUTE_ADJUST_ONLY)
is a variant of absolute behavior (DEVICE_VOLUME_BEHAVIOR_ABSOLUTE).
Like ABSOLUTE, ADJUST_ONLY may be adopted by calling a hidden API in
AudioDeviceVolumeManager and providing a listener for volume changes.
The difference with ADJUST_ONLY behavior is that setting volume via
AudioManager#setStreamVolume does not necessarily have an effect.
However, the listener is still notified of setStreamVolume calls
in case there's a slow or less reliable method of setting volume.
ADJUST_ONLY behavior may be returned by getDeviceVolumeBehavior for
SDK level U or higher. For lower SDK levels, FULL volume behavior is
returned in its place, as it is a similar but less powerful behavior.
Bug: 240663182
Test: atest AbsoluteVolumeBehaviorTest
Change-Id: I389bdd650dee717c4b249c989f4a9ee21c4eded7
Diffstat (limited to 'libs/androidfw/ApkParsing.cpp')
0 files changed, 0 insertions, 0 deletions