Highlighting nodes in a JTree

how can i do this, which object in the tree recibe Mouse or MouseMotion events?Thanks!
[100 byte] By [franmorenoa] at [2007-9-30 2:19:45]
# 1
use JTree.getClosestPathForLocation(int x, int y) or JTree.getClosestRowForLocation(int x, int y) with the x and y values from your event
mshn02a at 2007-7-16 13:28:46 > top of Java-index,Archived Forums,Swing...
# 2
write a tree node renderer and it'll tell you if the node is selected, then you draw it however you want selected nodes to look.
bsampieria at 2007-7-16 13:28:46 > top of Java-index,Archived Forums,Swing...