public void valueChanged(TreeSelectionEvent e) { MetaElement me = this.getSelectedMetaElement(); if ((me != null) && (status != null)) { status.setStatus("Element '" + me.getName() + "' selected.", true); } }
private void initElement(DefaultMutableTreeNode parent, MetaElement element) { DefaultMutableTreeNode node; for (MetaNode child : element.getChildren()) { if (child instanceof MetaElement) { node = new DefaultMutableTreeNode(child); this.model.insertNodeInto(node, parent, parent.getChildCount()); this.initElement(node, (MetaElement) child); } } }