public static void toggleExpansion(Node currentNode, JoeTree tree, OutlineLayoutManager layout, boolean shiftDown) {
		JoeNodeList nodeList = tree.getSelectedNodes();
		for (int i = 0, limit = nodeList.size(); i < limit; i++) {
			Node node = nodeList.get(i);
			if (node.isExpanded()) {
				node.setExpanded(false, !shiftDown);
			} else {
				if (shiftDown) {
					node.ExpandAllSubheads();
				} else {
					node.setExpanded(true, true);
				}
			}
		}

		layout.draw(currentNode, OutlineLayoutManager.ICON);
	}