Hello, I'm trying to get the open state for folders while drawing a TreeViewComponent but itemIndex is reseted for each subfolder:
bool isOpen = (dynamic_cast <TreeView *> (&dcc))->getItemOnRow(itemIndex)->isOpen();
itemIndex example values:
directory 1 - itemIndex = 0
directory 2 - itemIndex = 1
dir2subdir1 - itemIndex = 0 ! should be 2 in order to use it with getItemOnRow()directory 3 - itemIndex = 2 ! should be 3 (tells me its not open since dir2subdir1 isn't open)
dir3subdir1 - itemIndex = 0 ! should be 4...
Did I miss something? Should it be done differently?
Thank you! =)