How do you display the rating attributes icon on the descriptions screen? Previously, if setup the content-data correctly for roSpringboardScreen, the attributes were displayed correctly. But, since that has been deprecated, are you supposed to use a Poster to display the icon? If so, do you get them from ‘common:/’?
I created a horizontal LayoutGroup to display release date, rating and hd icon.
Then in the brs file, in OnContentChange(), I update the text/icons appropriately, I used text for rating, but you can use icons if you have them or create them.
Sub OnContentChanged()
item = m.top.content
spacings = [15, 15, 15]
'release date[/color]
if item.releaseDate <> invalid and item.releaseDate <> “”
m.top.releaseDate.text = item.releaseDate.split(“/”)[2] 'year
else
m.top.releaseDate.text = “”
spacings[0] = 0
end if
'rating[/color]
’ if item.rating = “G”
’ m.top.rating.uri = “pkg:/images/g.png”
’ else if item.rating = “NC-17”
’ m.top.rating.uri = “pkg:/images/nc17.png”
’ else if item.rating = “PG”
’ m.top.rating.uri = “pkg:/images/pg.png”
’ else if item.rating = “PG-13”
’ m.top.rating.uri = “pkg:/images/pg13.png”
’ else if item.rating = “R”
’ m.top.rating.uri = “pkg:/images/r.png”
’ else if item.rating = “NR”
’ m.top.rating.uri = “pkg:/images/nr.png”
’ else if item.rating = “TV-Y”
’ m.top.rating.uri = “pkg:/images/tvy.png”
’ else if item.rating = “TV-Y7”
’ m.top.rating.uri = “pkg:/images/tvy7.png”
’ else if item.rating = “TV-Y7-FV”
’ m.top.rating.uri = “pkg:/images/tvy7fv.png”
’ else if item.rating = “TV-G”
’ m.top.rating.uri = “pkg:/images/tvg.png”
’ else if item.rating = “TV-PG”
’ m.top.rating.uri = “pkg:/images/tvpg.png”
’ else if item.rating = “TV-14”
’ m.top.rating.uri = “pkg:/images/tv14.png”
’ else if item.rating = “TV-MA”
’ m.top.rating.uri = “pkg:/images/tvma.png”
’ else
’ m.top.rating.uri = “pkg:/images/ur.png”
’ end if
if item.rating = invalid or item.rating = “”
m.top.rating.text = “NR”
else
m.top.rating.text = item.rating
end if
m.top.itemSpacings = spacings
End Sub
I managed spacings between items to ensure that things were spaced correctly for ex. if the release date was missing.