Find TreeNode at a specific point

I have a JTree with MouseListener for right click search. When the user clicks, I get a MouseEvent containing the source, JTree .

How can I get the DefaultMutableTreeNode right click?

I was thinking about getting Node in Point represented in mouseEvent.getLocationOnScreen() , but I don't know how

Can you help me?

+4
source share
1 answer

Source: https://habr.com/ru/post/1391295/


All Articles