Skip to content

MediaSession ACTION_FAST_FORWARD should be disabled if player cannot seekTo #4001

@izderadicka

Description

@izderadicka

Issue description

I have client using MediaControlerCompat with MediaSession extension from Exoplayer.
When playing media with unknown length (http stream chunk encoded) the seeking is disabled.
(state actions does not allow ACTION_SEEK_TO).
However state does enable action ACTION_FAST_FORWARD, which is implemented in MediaSessionConnector as seeking to current position plus defined offset.
So obviously if seeking is not possible, fast forward is not working too (actually goes to start of the stream).

So my expectation would be that ACTION_FAST_FORWARD should be also disabled when ACTION_SEEK_TO is disabled. Or is there some deeper logic?

Of course it's no big issue to check for both on client side, however I thought that connector should handle this logic, as it is using seek for fast forward. Same also for ACTION_REWIND.

Reproduction steps

Any client using playing http chunk encoded stream - in my case it's transcoded audio in ogg+opus.
Check actions available in PlaybackStateCompact - if ACTION_SEEK_TO is not allowed then ACTION_FAST_FORWARD and ACTION_REWIND should not be allowed too.

Link to test content

Unfortunately my stream are on private server. But I believe any chunk encoded http stream will behave same way.

Version of ExoPlayer being used

2.7.0

Device(s) and version(s) of Android being used

emulated Android 7.0
Samsung A3 with Android 7.0

A full bug report captured from the device

As this is rather question about logic of the connector I do not provide it now.
If necessary for detailed examination I can provide later,

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions