added more fixes for deselecting ndoe in tree