Added event methods for clicking on the tree nodes.