begin new persondetails view

This commit is contained in:
sevenrats 2023-02-01 03:54:58 -05:00
parent d26ad4a181
commit 99d5968762
2 changed files with 32 additions and 37 deletions

View File

@ -2,7 +2,6 @@ sub init()
m.dscr = m.top.findNode("description")
m.vidsList = m.top.findNode("extrasGrid")
m.btnGrp = m.top.findNode("buttons")
m.btnGrp.observeField("escape", "onButtonGroupEscaped")
m.favBtn = m.top.findNode("favorite-button")
m.extrasGrp = m.top.findNode("extrasGrp")
m.top.findNode("VertSlider").keyValue = "[[30, 998], [30, 789], [30, 580], [30,371 ], [30, 162]]"
@ -67,17 +66,6 @@ sub dscrShowFocus()
end if
end sub
sub onButtonGroupEscaped()
key = m.btnGrp.escape
if key = "down"
m.vidsList.setFocus(true)
m.top.findNode("VertSlider").reverse = false
m.top.findNode("pplAnime").control = "start"
else if key = "up" and m.dscr.isTextEllipsized
dscrShowFocus()
end if
end sub
function onKeyEvent(key as string, press as boolean) as boolean
if not press then return false
@ -95,17 +83,31 @@ function onKeyEvent(key as string, press as boolean) as boolean
end if
if key = "down"
if m.favBtn.hasFocus()
m.dscr.setFocus(true)
m.dscr.opacity = 1.0
m.top.findNode("dscrBorder").color = "#d0d0d0ff"
return true
else if m.dscr.hasFocus()
m.dscr.opacity = 0.6
m.top.findNode("dscrBorder").color = "#data202020ff"
m.vidsList.setFocus(true)
m.top.findNode("VertSlider").reverse = false
m.top.findNode("pplAnime").control = "start"
return true
end if
else if key = "up"
if m.dscr.hasFocus()
m.favBtn.setFocus(true)
m.dscr.opacity = 0.6
m.top.findNode("dscrBorder").color = "#data202020ff"
return true
end if
else if key = "up"
if m.vidsList.isInFocusChain() and m.vidsList.itemFocused = 0
else if m.vidsList.isInFocusChain() and m.vidsList.itemFocused = 0
m.top.findNode("VertSlider").reverse = true
m.top.findNode("pplAnime").control = "start"
m.favBtn.setFocus(true)
m.dscr.setFocus(true)
m.dscr.opacity = 1.0
m.top.findNode("dscrBorder").color = "#d0d0d0ff"
return true
end if
end if

View File

@ -6,33 +6,26 @@
<field id="selectedItem" type="node" alias="extrasGrid.selectedItem" alwaysNotify="true" />
</interface>
<children>
<LayoutGroup id="main_group"
layoutdirection="vert" translation="[60, 180]" itemSpacings="[36]">
<LayoutGroup id="personInfoGroup"
layoutDirection="horiz" itemSpacings="[36]">
<Poster id="personImage"
width="300" height="450" />
<LayoutGroup id="main_group" layoutdirection="vert" translation="[60, 180]" itemSpacings="[36]">
<LayoutGroup id="BannerGroup" layoutDirection="horiz" itemSpacings="[36]">
<LayoutGroup id="TitleGroup" layoutDirection="vert">
<Label id="name" font="font:LargeBoldSystemFont" height="60" width="1300" />
<label id="premierDate" font="font:SmallestBoldSystemFont" height="48" vertAlign="top" />
</LayoutGroup>
<Button id="favorite-button" text="Favorite" iconUri="" focusedIconUri="" />
</LayoutGroup>
<LayoutGroup id="personInfoGroup" layoutDirection="horiz" itemSpacings="[36]">
<Poster id="personImage" width="400" height="600" />
<LayoutGroup id="vertSpacer" layoutDirection="vert" itemSpacings="[24]">
<LayoutGroup id="dataGroup>" layoutDirection="vert"
translation="[450,180]">
<Label id="name" font="font:MediumBoldSystemFont" height="45" width="1200" />
<label id="premierDate" font="font:SmallestBoldSystemFont" height="48" vertAlign="top" />
<Rectangle id="dscrBorder"
height="360" width="1422"
color="0x202020ff">
<Rectangle id='dscrRect' translation="[3, 3]"
height="354" width="1416"
color="0x202020ff">
<LayoutGroup id="dataGroup>" layoutDirection="vert" translation="[450,180]">
<Rectangle id="dscrBorder" height="600" width="1322" color="0x202020ff">
<Rectangle id='dscrRect' translation="[3, 3]" height="594" width="1316" color="0x202020ff">
<Label id="description"
height="342" width="1380" wrap="true" translation="[18, 15]"
height="600" width="1280" wrap="true" translation="[18, 15]" opacity="0.6"
font="font:SmallestSystemFont" color="#e4e4e4ff" ellipsisText=" ... (-OK- for More)" />
</Rectangle>
</Rectangle>
</LayoutGroup>
<ButtonGroupHoriz id="buttons" >
<Button id="favorite-button" text="Favorite"
iconUri="" focusedIconUri="" />
</ButtonGroupHoriz>
</LayoutGroup>
</LayoutGroup>
</LayoutGroup>