Avrcp: refactor addressed player notifications
The time when audio players change is a time of great changes in the Media
Framework. Many things are updated at the same time, and controllers
are updating three or four times before Metadata is stable for sending
to the controller.
Accordingly, when media updates happen, we can wait a little bit to
update media info when it changes to let it settle.
Refactor sending addressed player changes, resetting notifications when
we are supposed to, and check for an update whenever we update media.
Only update media at max every second.
Test: connect to carkit, change apps, notice media appears
Bug: 34471252
Change-Id: I6f0a5e169bece69894d1139a2b6615fac6b08a48
1 file changed