DefaultMutableTreeNode node = getSelectedNode(); while (!node.getAllowsChildren()) node = (DefaultMutableTreeNode)node.getParent(); if (!node.equals(getSelectedNode())) workspace.setSelectionPath(new TreePath(node.getPath())); newSociety();
saveRecipe();
	public void actionPerformed(ActionEvent e) {          // TODO: its unclear when you would get to this point          // and not have a node that allows children          DefaultMutableTreeNode node = getSelectedNode();          while (!node.getAllowsChildren())             node = (DefaultMutableTreeNode)node.getParent();          if (!node.equals(getSelectedNode()))            workspace.setSelectionPath(new TreePath(node.getPath()));          newSociety();	}