Sub CreateListItem(Text As String, Width As Int, Height As Int, something as boolean) As Panel
Dim p As Panel
p.Initialize("")
p.SetLayout(0, 0, Width, Height)
if something then
p.LoadLayout("CellItem1")
else
p.LoadLayout("CellItem2")
end if
Label1.Text = Text
Return p
End Sub