media/libraries
bachinger e54a934398 Precedence for app provided media button receiver
This change selects the best suited media button receiver
component and pending intent when creating the legacy
session. This is important to ensure that a service can
be started with a media button event from BT headsets
after the app has been terminated.

The `MediaSessionLegacyStub` selects the best suited
receiver to be passed to the `MediaSessionCompat`
constructor.

1. When the app has declared a broadcast receiver for
 `ACTION_MEDIA_BUTTON` in the manifest, this broadcast
 receiver is used.
2. When the session is housed in a service, the service
 component is used as a fallback.
3. As a last resort a receiver is created at runtime.

When the `MediaSessionLegacyStub` is released, the media
button receiver is removed unless the app has provided a
media button receiver in the manifest. In this case we
assume the app supports resuming when the BT play intent
arrives at `MediaSessionService.onStartCommand`.

#minor-release

Issue: androidx/media#167
Issue: androidx/media#27
Issue: androidx/media#314
PiperOrigin-RevId: 523638051
2023-04-12 16:56:44 +01:00
..
cast Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
common Remove setters for streamOffset. 2023-04-12 16:52:48 +01:00
database Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
datasource Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
datasource_cronet Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
datasource_okhttp Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
datasource_rtmp Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
decoder Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
decoder_av1 Remove Javadoc TODO from README of decoder extensions 2023-04-05 15:48:58 +01:00
decoder_ffmpeg Remove Javadoc TODO from README of decoder extensions 2023-04-05 15:48:58 +01:00
decoder_flac Remove Javadoc TODO from README of decoder extensions 2023-04-05 15:48:58 +01:00
decoder_opus Remove Javadoc TODO from README of decoder extensions 2023-04-05 15:48:58 +01:00
decoder_vp9 Remove Javadoc TODO from README of decoder extensions 2023-04-05 15:48:58 +01:00
effect Remove setters for streamOffset. 2023-04-12 16:52:48 +01:00
exoplayer Rename ExoTrackSelection.blacklist to excludeTrack 2023-04-12 16:54:45 +01:00
exoplayer_dash Rename ExoTrackSelection.blacklist to excludeTrack 2023-04-12 16:54:45 +01:00
exoplayer_hls Rename ExoTrackSelection.blacklist to excludeTrack 2023-04-12 16:54:45 +01:00
exoplayer_ima Correct ad durations when timeline moves more than a single period 2023-04-11 10:30:27 +01:00
exoplayer_rtsp Move NAL unit utility classes into common 2023-04-05 15:45:35 +01:00
exoplayer_smoothstreaming Rename ExoTrackSelection.blacklist to excludeTrack 2023-04-12 16:54:45 +01:00
exoplayer_workmanager Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
extractor Move NAL unit utility classes into common 2023-04-05 15:45:35 +01:00
session Precedence for app provided media button receiver 2023-04-12 16:56:44 +01:00
test_data HDR: Add HDR pixel tests. 2023-04-12 16:51:51 +01:00
test_exoplayer_playback Fix instrumentation tests not working via Gradle 2022-09-30 18:03:11 +00:00
test_session_common Update available commands when setting a new player in MediaSession 2023-04-12 16:55:47 +01:00
test_session_current Update available commands when setting a new player in MediaSession 2023-04-12 16:55:47 +01:00
test_utils Rename ExoTrackSelection.blacklist to excludeTrack 2023-04-12 16:54:45 +01:00
test_utils_robolectric Fix javadoc links in media README files 2023-03-30 17:26:40 +00:00
transformer HDR: Add HDR pixel tests. 2023-04-12 16:51:51 +01:00
ui Make PlayerView fold aware 2023-04-12 16:51:04 +01:00
ui_leanback Fix (another) LeanbackPlayerAdapter param name mismatch 2023-02-01 10:41:50 +00:00