optimized treeview rendering