PlayableFolderActivity currently uses two seperate commands
to set the playlist and then seek to the requested item.
This is slightly inefficient and also causes analytics
listeners to believe the first item in the playlist was
briefly active.
#minor-release
Issue: androidx/media#180
PiperOrigin-RevId: 480031682
Replacing remaining usage of MoreExecutors.directExecutor. This allows the service to be switched to run in another process and the app still works the same as if it is running in the same process.
Issue: androidx/media#100
PiperOrigin-RevId: 471547177
This allows the service to be switched to run in another process and the app still works the same as if it is running in the same process.
Issue: androidx/media#100
PiperOrigin-RevId: 458460005
These legacy callbacks are currently forwarded to onSetMediaUri which
will be removed in the future.
Also make sure to only call player.prepare/play after the items have
been set.
The calls to onAddQueueItem are also forwarded to onAddMediaItems to
actually allow a session to resolve these items to playable media, which
wasn't possible so far.
PiperOrigin-RevId: 453625204
The MediaItemFiller is not flexible enough for most realworld usages
because:
- it doesn't allow asynchronous resolution of MediaItems (e.g. to
look up URIs from a database)
- it doesn't allow to batch updates for multiple items or do more
advanced customizations (e.g. expanding a mediaId representing
a playlist to multiple items).
Both issues can be solved by passing in a list of items and
returning a ListenableFuture. The callback itself can also move
into MediaSession.Callback for consistency with the other
callbacks.
PiperOrigin-RevId: 451857319
Immediately notify a subscribing client about the availability of child items of
a parent ID to make the client load the children.
PiperOrigin-RevId: 450396690
This change fixes two bugs where MediaSessionServe shows a notification
with the Play icon but tapping it will not start playback:
1. After playback ends: we need to seek to the beginning of the media
item.
2. After adding media items to the player but not starting playback:
We need to call Player.prepare() too.
PiperOrigin-RevId: 432469953
Where this introduced an inconsistency (e.g. assigning to something
called `windowIndex`), I generally renamed the transitive closure of
identifiers to maintain consistency (meaning this change is quite
large). The exception is code that interacts with Timeline and Window
directly, where sometimes I kept the 'window' nomenclature.
#minor-release
PiperOrigin-RevId: 407040052