Skip to content

Commit

Permalink
Merge pull request #1688 from cewert/sync-master
Browse files Browse the repository at this point in the history
  • Loading branch information
cewert authored Feb 6, 2024
2 parents ddfb73c + 1999cf5 commit 31f91c7
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# If you want to get_images, you'll also need convert from ImageMagick
##########################################################################

VERSION := 2.0.2
VERSION := 2.0.3

## usage

Expand Down
9 changes: 8 additions & 1 deletion components/ItemGrid/LoadVideoContentTask.bs
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,14 @@ function defaultSubtitleTrackFromVid(videoID) as integer
if not isValidAndNotEmpty(meta.json.MediaSources[0].MediaStreams) then return SubtitleSelection.none

subtitles = sortSubtitles(meta.id, meta.json.MediaSources[0].MediaStreams)
selectedAudioLanguage = meta.json.MediaSources[0].MediaStreams[m.top.selectedAudioStreamIndex].Language ?? ""

selectedAudioLanguage = ""
audioMediaStream = meta.json.MediaSources[0].MediaStreams[m.top.selectedAudioStreamIndex]

' Ensure audio media stream is valid before using language property
if isValid(audioMediaStream)
selectedAudioLanguage = audioMediaStream.Language ?? ""
end if

defaultTextSubs = defaultSubtitleTrack(subtitles["text"], selectedAudioLanguage, true) ' Find correct subtitle track (forced text)
if defaultTextSubs <> SubtitleSelection.none
Expand Down
2 changes: 1 addition & 1 deletion manifest
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
title=Jellyfin
major_version=2
minor_version=0
build_version=2
build_version=3

### Main Menu Icons / Channel Poster Artwork

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "jellyfin-roku",
"type": "module",
"version": "2.0.2",
"version": "2.0.3",
"description": "Roku app for Jellyfin media server",
"dependencies": {
"@rokucommunity/bslib": "0.1.1",
Expand Down
14 changes: 13 additions & 1 deletion source/Main.bs
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,19 @@ sub Main (args as dynamic) as void
end if

' Display playback options dialog
if selectedItem.json.userdata.PlaybackPositionTicks > 0
showPlaybackOptionDialog = false

if isValid(selectedItem.json)
if isValid(selectedItem.json.userdata)
if isValid(selectedItem.json.userdata.PlaybackPositionTicks)
if selectedItem.json.userdata.PlaybackPositionTicks > 0
showPlaybackOptionDialog = true
end if
end if
end if
end if

if showPlaybackOptionDialog
dialog.close = true
m.global.queueManager.callFunc("hold", selectedItem)
playbackOptionDialog(selectedItem.json.userdata.PlaybackPositionTicks, selectedItem.json)
Expand Down
10 changes: 10 additions & 0 deletions source/static/whatsNew/2.0.3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[
{
"description": "Fix playback of movie additional parts",
"author": "1hitsong"
},
{
"description": "Fix crash if video has no audio stream",
"author": "1hitsong"
}
]

0 comments on commit 31f91c7

Please sign in to comment.