Skip to content

Commit

Permalink
Merge pull request #2118 from jellyfin/jf-2.3.0-fixes
Browse files Browse the repository at this point in the history
Final touches on 2.3.0
  • Loading branch information
jimdogx authored Feb 1, 2025
2 parents 677ca44 + df704cb commit 6641dcd
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 3 deletions.
15 changes: 14 additions & 1 deletion components/movies/MovieDetails.bs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import "pkg:/source/utils/misc.bs"
import "pkg:/source/utils/config.bs"
import "pkg:/source/api/Image.bs"

sub init()
m.extrasGrp = m.top.findnode("extrasGrp")
Expand Down Expand Up @@ -100,7 +101,19 @@ sub itemContentChanged()
userSettings = m.global.session.user.settings
itemData = item.json
m.top.id = itemData.id
m.top.findNode("moviePoster").uri = m.top.itemContent.posterURL

posterUrl = item.posterURL

' Really need to update TvShowDetails to include the options for changing audio tracks etc
' so that we can use that instead of MovieDetails when a user clicks on a TV Show in "Next Up"
if LCase(itemData.type) = "episode" and IsValid(itemData.ImageTags)
m.moviePoster.width = 464
m.moviePoster.height = 261
params = { "Tag": itemData.ImageTags.Primary, "maxHeight": 261, "maxWidth": 464 }
posterUrl = ImageURL(itemData.id, "Primary", params)
end if

m.moviePoster.uri = posterUrl

' Set default video source if user hasn't selected one yet
if m.top.selectedVideoStreamId = "" and isValid(itemData.MediaSources)
Expand Down
8 changes: 7 additions & 1 deletion components/search/SearchRow.bs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ sub updateSize()
m.top.itemSpacing = [0, 105]

m.top.rowItemSize = [itemWidth, itemHeight]
m.top.rowItemSpacing = [0, 0]
m.top.rowItemSpacing = [40, 0]
m.top.numRows = 2
m.top.translation = "[12,18]"
end sub
Expand Down Expand Up @@ -84,10 +84,16 @@ function getData()
end function

sub addRow(data, title, type_filter)
startDate = createObject("roDateTime")

itemData = m.top.itemData
row = data.CreateChild("ContentNode")
row.title = title
for each item in itemData.Items
if LCase(item.type) = "program" and isValid(item.json.StartDate)
startDate.FromISO8601String(item.json.StartDate)
item.title += " - " + startDate.AsDateString("short-date") + " " + startDate.AsTimeStringLoc("short")
end if
if item.type = type_filter
row.appendChild(item)
end if
Expand Down
2 changes: 1 addition & 1 deletion source/Main.bs
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,7 @@ sub Main (args as dynamic) as void
m.global.queueManager.callFunc("playQueue")
else if node.type = "Person"
group = CreatePersonView(node)
else if node.type = "TvChannel"
else if node.type = "TvChannel" or node.type = "Program"
group = CreateVideoPlayerGroup(node.id)
sceneManager.callFunc("pushScene", group)
else if node.type = "Episode"
Expand Down

0 comments on commit 6641dcd

Please sign in to comment.