bitmovin / bitmovin-player-ui

The Bitmovin Adaptive Streaming Player UI
MIT License
126 stars 87 forks source link

Add Fast-Forward/Rewind button components #623

Closed dweinber closed 5 months ago

dweinber commented 5 months ago

Description

This PR adds a new QuickSeekButton component for the control bar. Via the configuration, it can be defined whether it should be a rewind or a fast-forward button. Further, the time that is skipped in the respective direction is configurable.

Please note that the component is exported for custom, externally managed UIs, but it is not added to the default UI variants.

Checklist (for PR submitter and reviewers)

This is how it looks like when added:

Screenshot 2024-05-16 at 15 06 00

Screenshot 2024-05-16 at 15 05 46

dweinber commented 5 months ago

Luckily most changes where just around the automated release process. Seems that all the actual UI changes still work well from what I can tell.

However, I just found a case I didn't handle correctly before: If you hit the QuickSeekButton a few times and we don't have data buffered for that area, the player's currentTime / getTimeShift hasn't changed yet. This means that the additional button clicks where ignored in that case. This is handled now in the last two commits, please take another look at these changes - thanks!