History log of /packages/apps/Bluetooth/src/com/android/bluetooth/avrcp/mockable/MediaController.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
3a80469f095e51f9be3965d67fff595eabc00293 06-Jun-2017 Marie Janssen <jamuraa@google.com> AVRCP: fix single item queue Now Playing issues

When queried (and in track change notifications) we previously returned
an item ID not allowed by the spec (0xFFFFFFFFFFFFFFFF) to a controller
when presenting a "single item queue" because the player doesn't provide
one.

Refactor the code so that the single item queue is persisted and send
NOW_PLAYING_CONTENT_CHANGED when the single item queue updates.

Tweak debugging of mediacontrollers for easier player debugging.

Test: check media info on honda carkit w/fm.player app
Bug: 62288178
Change-Id: Ic37d0c4c837436e102e9642e1f8e36e17e0dc254
/packages/apps/Bluetooth/src/com/android/bluetooth/avrcp/mockable/MediaController.java
384011244f5a62ed34f198b8ba91341b4efb4fb6 03-May-2017 Marie Janssen <jamuraa@google.com> AVRCP: Track players without active media sessions

Players can be selected as addressed by MediaSessionService, then
destroy and renew their MediaSession. We want them to continue to
be addressed.

Don't remove players that destroy their MediaSession, and just forget
the controller instead.

Remove players when their package is removed though.

Report "(unknown)" when we are asked for media info for an addressed
player that has no controller.

Fix a bug where we didn't send updated metadata when it changed.
Fix an ordering bug updating the media session.

Make logging more clear when we're adding / updating / removing players.
Add dumpsys log to confirm current mMediaController is correct.

Use @Nullable and @NonNull to help with distinguishing when
MediaController can be null in AddressedMediaPlayer.

Test: send pause / play from headset, look at bugreport to confirm
Change-Id: I083745f8988e67776716db2bec5e67b697e8ee67
Bug: 36357185
Fixes: 37865298
/packages/apps/Bluetooth/src/com/android/bluetooth/avrcp/mockable/MediaController.java
d996f17ea97b2c592338bcfbc93056d0224da1cd 21-Oct-2016 Ajay Panicker <apanicke@google.com> Add AVRCP unit tests and switch to using mockable interfaces

Add a mockable interface for MediaController in order to add unit
tests for AddressedMediaPlayer.

Bug: 32416674
Test: Tested manually
Change-Id: I081c37915fc15e58f3de37c3a16e03747503860c
/packages/apps/Bluetooth/src/com/android/bluetooth/avrcp/mockable/MediaController.java