mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
TreeUI: CCE fix
This commit is contained in:
@@ -482,10 +482,13 @@ public class AbstractTreeUi {
|
||||
@Nullable
|
||||
private static NodeDescriptor getDescriptorFrom(Object node) {
|
||||
if (node instanceof DefaultMutableTreeNode) {
|
||||
return (NodeDescriptor)((DefaultMutableTreeNode)node).getUserObject();
|
||||
} else {
|
||||
return null;
|
||||
Object userObject = ((DefaultMutableTreeNode)node).getUserObject();
|
||||
if (userObject instanceof NodeDescriptor) {
|
||||
return (NodeDescriptor)userObject;
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
|
||||
Reference in New Issue
Block a user