-
-
Notifications
You must be signed in to change notification settings - Fork 509
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement media segments #4052
Implement media segments #4052
Conversation
@@ -64,7 +64,7 @@ | |||
private Limiter mLimiter; | |||
private PlaybackControllerNotifiable mPlaybackControllerNotifiable; | |||
private PlaybackOverlayFragmentHelper _helper; | |||
private ExoPlayer mExoPlayer; | |||
public ExoPlayer mExoPlayer; |
Check notice
Code scanning / Android Lint
Unknown nullness Note
NOTHING(R.string.segment_action_nothing), | ||
|
||
/** | ||
* Seek to the end of this segment (endTicks). If the duration of this segment is shorter than 1 second it should do nothing to avoid |
Check warning
Code scanning / detekt
Line detected, which is longer than the defined maximum line length in the code style. Warning
app/src/main/java/org/jellyfin/androidtv/ui/playback/segment/MediaSegmentAction.kt
Fixed
Show fixed
Hide fixed
app/src/main/java/org/jellyfin/androidtv/ui/playback/segment/MediaSegmentAction.kt
Fixed
Show fixed
Hide fixed
app/src/main/java/org/jellyfin/androidtv/ui/playback/PlaybackControllerHelper.kt
Fixed
Show fixed
Hide fixed
app/src/main/java/org/jellyfin/androidtv/ui/playback/PlaybackControllerHelper.kt
Fixed
Show fixed
Hide fixed
|
||
/** | ||
* Seek to the end of this segment (endTicks). If the duration of this segment is shorter than 1 second it should do nothing to avoid | ||
* lagg. The skip action will only execute when playing over the segment start, not when seeking into the segment block. |
Check warning
Code scanning / detekt
Line detected, which is longer than the defined maximum line length in the code style. Warning
app/src/main/java/org/jellyfin/androidtv/ui/playback/segment/MediaSegmentAction.kt
Fixed
Show fixed
Hide fixed
48cdeda
to
941317d
Compare
941317d
to
6cdec33
Compare
Most of the proposed changes in the files listed below have been shamelessly copied from the Android TV implementation in jellyfin/jellyfin-androidtv#4052. Authorship of these changes belongs to nielsvanvelzen. app/src/main/java/org/jellyfin/mobile/player/PlayerViewModel.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentAction.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentRepository.kt
Most of the proposed changes in the files listed below have been shamelessly copied from the Android TV implementation in jellyfin/jellyfin-androidtv#4052. Authorship of these changes belongs to nielsvanvelzen. app/src/main/java/org/jellyfin/mobile/player/PlayerViewModel.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentAction.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentRepository.kt
Most of the proposed changes in the files listed below have been shamelessly copied from the Android TV implementation in jellyfin/jellyfin-androidtv#4052. Authorship of these changes belongs to nielsvanvelzen. app/src/main/java/org/jellyfin/mobile/player/PlayerViewModel.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentAction.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentRepository.kt app/src/main/java/org/jellyfin/mobile/utils/extensions/MediaSegment.kt
Most of the proposed changes in the files listed below have been shamelessly copied from the Android TV implementation in jellyfin/jellyfin-androidtv#4052. Authorship of these changes belongs to nielsvanvelzen. app/src/main/java/org/jellyfin/mobile/player/PlayerViewModel.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentAction.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentRepository.kt app/src/main/java/org/jellyfin/mobile/utils/extensions/MediaSegment.kt
Most of the proposed changes in the files listed below have been shamelessly copied from the Android TV implementation in jellyfin/jellyfin-androidtv#4052. Authorship of these changes belongs to nielsvanvelzen. app/src/main/java/org/jellyfin/mobile/player/PlayerViewModel.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentAction.kt app/src/main/java/org/jellyfin/mobile/player/mediasegments/MediaSegmentRepository.kt app/src/main/java/org/jellyfin/mobile/utils/extensions/MediaSegment.kt
This adds the initial support for media segments with some of the actions I'd like still missing.
Changes
The
MediaSegmentRepository
contains a hardcoded list of supported segment types that is always included when requesting segments. This way we can add new segment types on the backend without breaking existing app releases (SDK won't be able to parse an unknown enum). Additionally, I've opted to not support the "unknown" type in the client.Future additions will include:
I'm not sure how many of these will be implemented within the current playback code as it's a bit finicky to work with.
Screenshots
Issues