Skip to content

Commit

Permalink
Merge pull request #1886 from cewert/fix-homeitem-crash2
Browse files Browse the repository at this point in the history
  • Loading branch information
cewert authored Jul 31, 2024
2 parents 6347149 + fba290f commit 329a796
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion components/home/HomeItem.bs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ sub init()
end if

' update the backdrop node
m.backdrop = m.top.findNode("backdrop")
initBackdrop()
m.backdrop.color = backdropColor
end sub

Expand All @@ -46,6 +46,10 @@ sub initItemTextExtra()
m.itemTextExtra = m.top.findNode("itemTextExtra")
end sub

sub initBackdrop()
m.backdrop = m.top.findNode("backdrop")
end sub

sub itemContentChanged()
if isValid(m.unplayedCount) then m.unplayedCount.visible = false
itemData = m.top.itemContent
Expand All @@ -58,6 +62,7 @@ sub itemContentChanged()
if not isValid(m.itemPoster) then initItemPoster()
if not isValid(m.itemText) then initItemText()
if not isValid(m.itemTextExtra) then initItemTextExtra()
if not isValid(m.backdrop) then initBackdrop()

m.itemPoster.width = itemData.imageWidth
m.itemText.maxWidth = itemData.imageWidth
Expand Down

0 comments on commit 329a796

Please sign in to comment.