jf-roku/components/data/collection.xml
2019-04-14 19:19:06 -05:00

34 lines
920 B
XML

<?xml version="1.0" encoding="utf-8" ?>
<component name="CollectionData" extends="ContentNode">
<interface>
<field id="id" type="string" />
<field id="title" type="string" />
<field id="posterUrl" type="string" />
<field id="collectionID" type="string" />
<field id="description" type="string" />
<field id="favorite" type="boolean" />
<field id="watched" type="boolean" />
<field id="json" type="associativearray" onChange="setFields" />
</interface>
<script type="text/brightscript">
<![CDATA[
sub setFields()
datum = m.top.json
m.top.id = datum.id
m.top.title = datum.name
m.top.overview = datum.overview
m.top.favorite = datum.UserData.isFavorite
m.top.watched = datum.UserData.played
if datum.posterURL <> invalid
m.top.posterURL = datum.posterURL
else
m.top.posterURL = ""
end if
end sub
]]>
</script>
</component>