Hi Guys:
I am trying to make a list view, which need to show/hide the sub row when tap on the category’s name.
For example: tap on Breakfast to hide “coffee”, “Bagel”, “Toast” and tap on Breakfast again to show them.
I guess I can do it easily if I remove all the list and “list:insertRow” again to make a new one with out those sub row. But I am working with a long list, remove/ make new one may cause too much trouble for the CPU.
So is there a way to show/hide them except make a new list?
I was thinking about set the row’s height to 0 like when we make them
list:insertRow{
height = 30,
onRender = onRowRender,
isCategory = true,
listener = onTitleTouch }
But when I try to print the height of the row I taped, by
print( "Pressed row's height: " , list[row.index].height)
It shows the height is 206.
Is there a way to set this height after the list was made?
I think I can try to delete those sub rows, but this could ends up a mess when try to add them back. I have about 400-1000 rows.
Also it will be great if there is a easier way to change the row’s image to another one like buttons.
hudMainBt[i] = widget.newButton{
default = hudMainBtN[i].."Active.png",
over = hudMainBtN[i].."Press.png",
width = hudMainBtSX[i],
height = hudMainBtSY[i],
onRelease = hudMainBtHandle,}
Thanks [import]uid: 81853 topic_id: 35550 reply_id: 335550[/import]