void (@NotNull List<IntentionActionMetaData> sortedIntentions) { CheckedTreeNode root = new CheckedTreeNode(null); DefaultTreeModel treeModel = (DefaultTreeModel)myTree.getModel(); for (IntentionActionMetaData metaData : sortedIntentions) { CheckedTreeNode node = root; for (String name : metaData.myCategory) { CheckedTreeNode child = findChild(node, name); if (child == null) { CheckedTreeNode newChild = new CheckedTreeNode(name); treeModel.insertNodeInto(newChild, node, node.getChildCount()); child = newChild; } node = child; } treeModel.insertNodeInto(new CheckedTreeNode(metaData), node, node.getChildCount()); } resetCheckMark(root); treeModel.setRoot(root); treeModel.nodeChanged(root); TreeUtil.expandAll(myTree); myTree.setSelectionRow(0); }