Skip to content

Commit 6641dcd

Browse files
authored
Merge pull request #2118 from jellyfin/jf-2.3.0-fixes
Final touches on 2.3.0
2 parents 677ca44 + df704cb commit 6641dcd

File tree

3 files changed

+22
-3
lines changed

3 files changed

+22
-3
lines changed

components/movies/MovieDetails.bs

+14-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import "pkg:/source/utils/misc.bs"
22
import "pkg:/source/utils/config.bs"
3+
import "pkg:/source/api/Image.bs"
34

45
sub init()
56
m.extrasGrp = m.top.findnode("extrasGrp")
@@ -100,7 +101,19 @@ sub itemContentChanged()
100101
userSettings = m.global.session.user.settings
101102
itemData = item.json
102103
m.top.id = itemData.id
103-
m.top.findNode("moviePoster").uri = m.top.itemContent.posterURL
104+
105+
posterUrl = item.posterURL
106+
107+
' Really need to update TvShowDetails to include the options for changing audio tracks etc
108+
' so that we can use that instead of MovieDetails when a user clicks on a TV Show in "Next Up"
109+
if LCase(itemData.type) = "episode" and IsValid(itemData.ImageTags)
110+
m.moviePoster.width = 464
111+
m.moviePoster.height = 261
112+
params = { "Tag": itemData.ImageTags.Primary, "maxHeight": 261, "maxWidth": 464 }
113+
posterUrl = ImageURL(itemData.id, "Primary", params)
114+
end if
115+
116+
m.moviePoster.uri = posterUrl
104117

105118
' Set default video source if user hasn't selected one yet
106119
if m.top.selectedVideoStreamId = "" and isValid(itemData.MediaSources)

components/search/SearchRow.bs

+7-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ sub updateSize()
3636
m.top.itemSpacing = [0, 105]
3737

3838
m.top.rowItemSize = [itemWidth, itemHeight]
39-
m.top.rowItemSpacing = [0, 0]
39+
m.top.rowItemSpacing = [40, 0]
4040
m.top.numRows = 2
4141
m.top.translation = "[12,18]"
4242
end sub
@@ -84,10 +84,16 @@ function getData()
8484
end function
8585

8686
sub addRow(data, title, type_filter)
87+
startDate = createObject("roDateTime")
88+
8789
itemData = m.top.itemData
8890
row = data.CreateChild("ContentNode")
8991
row.title = title
9092
for each item in itemData.Items
93+
if LCase(item.type) = "program" and isValid(item.json.StartDate)
94+
startDate.FromISO8601String(item.json.StartDate)
95+
item.title += " - " + startDate.AsDateString("short-date") + " " + startDate.AsTimeStringLoc("short")
96+
end if
9197
if item.type = type_filter
9298
row.appendChild(item)
9399
end if

source/Main.bs

+1-1
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,7 @@ sub Main (args as dynamic) as void
565565
m.global.queueManager.callFunc("playQueue")
566566
else if node.type = "Person"
567567
group = CreatePersonView(node)
568-
else if node.type = "TvChannel"
568+
else if node.type = "TvChannel" or node.type = "Program"
569569
group = CreateVideoPlayerGroup(node.id)
570570
sceneManager.callFunc("pushScene", group)
571571
else if node.type = "Episode"

0 commit comments

Comments
 (0)