Create popup with full TV series description

Fixes #1673
This commit is contained in:
1hitsong 2024-01-28 21:06:10 -05:00
parent 2a9ecce423
commit a5d49da8b6
3 changed files with 19 additions and 4 deletions

View File

@ -22,6 +22,11 @@ sub init()
"fontSize": 35,
"fontUri": "font:SystemFontFile",
"color": "#00a4dcFF"
},
"p": {
"fontSize": 27,
"fontUri": "font:SystemFontFile",
"color": "#EFEFEFFF"
}
}

View File

@ -12,6 +12,7 @@ sub init()
m.Shuffle = m.top.findNode("Shuffle")
m.extrasSlider.visible = true
m.seasons = m.top.findNode("seasons")
m.overview = m.top.findNode("overview")
end sub
sub itemContentChanged()
@ -194,11 +195,20 @@ function onKeyEvent(key as string, press as boolean) as boolean
if not press then return false
overview = m.top.findNode("overview")
if key = "options"
if m.overview.isTextEllipsized
if isAllValid([m.top.itemContent.json.name, m.top.itemContent.json.overview])
m.global.sceneManager.callFunc("standardDialog", m.top.itemContent.json.name, { data: ["<p>" + m.top.itemContent.json.overview + "</p>"] })
return true
end if
end if
return false
end if
topGrp = m.top.findNode("seasons")
bottomGrp = m.top.findNode("extrasGrid")
if key = "down" and overview.hasFocus()
if key = "down" and m.overview.hasFocus()
m.Shuffle.setFocus(true)
return true
else if key = "down" and m.Shuffle.hasFocus()
@ -222,7 +232,7 @@ function onKeyEvent(key as string, press as boolean) as boolean
m.Shuffle.setFocus(true)
return true
else if key = "up" and m.Shuffle.hasFocus()
overview.setFocus(true)
m.overview.setFocus(true)
return true
else if key = "play" and m.seasons.hasFocus()
print "play was pressed from the seasons row"

View File

@ -19,7 +19,7 @@
</LayoutGroup>
<Label id="genres" />
<Label id="tagline" />
<Label id="overview" wrap="true" width="1400" maxLines="4" />
<Label id="overview" wrap="true" width="1400" maxLines="4" ellipsisText=" ... (Press * to read more)" />
<Label id="history" />
<JFButton id="Shuffle" minChars="15" text="Shuffle" translation="[90, 640]" visible="false"></JFButton>
</LayoutGroup>