Set device volume when AudioManager says device is connected
Instead of setting the remembered volume before the active device switch
happens, set it once we get a callback from the AudioManager that the
device has changed. This prevents the posibility of the new volume being
used with the old active device.
Bug: 79529581
Test: Switch devices multiple times and see that the volume changes when
the new device is connected.
Change-Id: I6a9e10654c844a5e2727d5409e27dd9e8176dd18
(cherry picked from commit 49f4ed0b5f63fc6de7287606e969b7a6c28a35c7)
Merged-In: I6a9e10654c844a5e2727d5409e27dd9e8176dd18
4 files changed