media/libraries
christosts b94ca4f2ad Only COMMAND_PLAY starts the service in the foreground
This change makes all notification actions start MediaSessionService
in the background except COMMAND_PLAY which starts the service
in the foreground. This is to avoid ANRs that are raised if we don't
call MediaSessionService.startForeground() within 5 seconds since the
service was started in the foreground.

We only call MediaSessionService.startForeground() when
Player.getPlayWhenReady() returns true, and only COMMAND_PLAY sets
playWhenReady to true.

Issue: androidx/media#20

#minor-release

PiperOrigin-RevId: 433229604
2022-03-09 15:09:27 +00:00
..
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-02-18 14:54:02 +00:00
2022-03-09 15:05:07 +00:00