public void readExternal(Element element) throws InvalidDataException { List<Element> subPanes = element.getChildren(ELEMENT_SUBPANE); for (Element subPane : subPanes) { String subId = subPane.getAttributeValue(ATTRIBUTE_SUBID); TreeState treeState = new TreeState(); treeState.readExternal(subPane); myReadTreeState.put(subId, treeState); } }
public void writeExternal(Element element) throws WriteExternalException { saveExpandedPaths(); for (String subId : myReadTreeState.keySet()) { TreeState treeState = myReadTreeState.get(subId); Element subPane = new Element(ELEMENT_SUBPANE); if (subId != null) { subPane.setAttribute(ATTRIBUTE_SUBID, subId); } treeState.writeExternal(subPane); element.addContent(subPane); } }
private void restoreState() { myTreeState.applyTo(this, (ChangesBrowserNode) getModel().getRoot()); }
private void storeState() { myTreeState = TreeState.createOn(this, (ChangesBrowserNode) getModel().getRoot()); }
public final void restoreExpandedPaths() { TreeState treeState = myReadTreeState.get(getSubId()); if (treeState != null) { treeState.applyTo(myTree); } }
protected void saveExpandedPaths() { if (myTree != null) { TreeState treeState = TreeState.createOn(myTree); myReadTreeState.put(getSubId(), treeState); } }