pinehead
15 years agoVisitor
Adding sdposterurl into array
I'm looping through video ep's (really only need one) and i'm trying to display an image for the entry. I've got everything to work but this. the documentation doesn't show how to do this in an array. Here is my code, you'll see o.SDPosterUrl:"file://pkg:/images/livestream.png" causes an error and so does SDPosterUrl:"file://pkg:/images/livestream.png". The documentation says i should be able to just place SDPosterURL. Perhaps i'm doing this wrong?
Thanks,
Function showHomeScreen(screen) As Integer
if type(screen)<>"roPosterScreen" then
print "illegal type/value for screen passed to showHomeScreen"
return -1
end if
' itemNames = getItemNames()
'screen.SetContentList(itemNames)
list = CreateObject("roArray", 10, true)
o = CreateObject("roAssociativeArray")
o.ContentType = "episode"
o.Title = ""
o.ShortDescriptionLine1 = ""
o.ShortDescriptionLine2 = ""
o.SDPosterUrl:"file://pkg:/images/l.png"
list.Push(o)
screen.SetContentList(list)
screen.Show()
while true
msg = wait(0, screen.GetMessagePort())
if type(msg) = "roPosterScreenEvent" then
print "showHomeScreen | msg = " + msg.GetMessage() + " | index = " + itostr(msg.GetIndex())
if msg.isListItemSelected() then
live()
else if msg.isScreenClosed() then
return -1
end if
end If
end while
End Function
Thanks,
Function showHomeScreen(screen) As Integer
if type(screen)<>"roPosterScreen" then
print "illegal type/value for screen passed to showHomeScreen"
return -1
end if
' itemNames = getItemNames()
'screen.SetContentList(itemNames)
list = CreateObject("roArray", 10, true)
o = CreateObject("roAssociativeArray")
o.ContentType = "episode"
o.Title = ""
o.ShortDescriptionLine1 = ""
o.ShortDescriptionLine2 = ""
o.SDPosterUrl:"file://pkg:/images/l.png"
list.Push(o)
screen.SetContentList(list)
screen.Show()
while true
msg = wait(0, screen.GetMessagePort())
if type(msg) = "roPosterScreenEvent" then
print "showHomeScreen | msg = " + msg.GetMessage() + " | index = " + itostr(msg.GetIndex())
if msg.isListItemSelected() then
live()
else if msg.isScreenClosed() then
return -1
end if
end If
end while
End Function