This commit is contained in:
jd1123 2021-04-18 22:27:11 -04:00
parent b1191d0e23
commit be3b410d20
3 changed files with 14 additions and 0 deletions

View File

@ -42,6 +42,7 @@ sub itemContentChanged()
m.itemPoster.uri = itemData.PosterUrl
m.itemText.text = itemData.Title
else if itemData.type = "Folder" then
m.itemPoster.uri = itemData.PosterUrl
m.itemIcon.uri = itemData.iconUrl
m.itemText.text = itemData.Title
else if itemData.type = "Video" then

View File

@ -6,4 +6,14 @@ sub setFields()
m.top.Type = "Folder"
m.top.iconUrl = "pkg:/images/media_type_icons/folder_white.png"
setPoster()
end sub
sub setPoster()
if m.top.image <> invalid
m.top.posterURL = m.top.image.url
else if m.top.json.ImageTags.Primary <> invalid then
imgParams = { "maxHeight": 440, "maxWidth": 295, "Tag": m.top.json.ImageTags.Primary }
m.top.posterURL = ImageURL(m.top.json.id, "Primary", imgParams)
end if
end sub

View File

@ -1,4 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<component name="FolderData" extends="JFContentItem">
<script type="text/brightscript" uri="FolderData.brs" />
<script type="text/brightscript" uri="pkg:/source/api/Image.brs" />
<script type="text/brightscript" uri="pkg:/source/api/baserequest.brs" />
<script type="text/brightscript" uri="pkg:/source/utils/config.brs" />
</component>