Mercurial > hg > graal-jvmci-8
view src/share/tools/IdealGraphVisualizer/ControlFlowEditor/src/at/ssw/visualizer/cfg/action/HierarchicalNodeLayoutAction.java @ 4487:aae5b3773e63
Added CFG editor from c1visualizer.
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Tue, 31 Jan 2012 00:23:10 +0100 |
parents | |
children | bf4c1e7d71b3 |
line wrap: on
line source
package at.ssw.visualizer.cfg.action; import at.ssw.visualizer.cfg.CfgEditorContext; import at.ssw.visualizer.cfg.editor.CfgEditorTopComponent; import at.ssw.visualizer.cfg.graph.CfgScene; import org.openide.util.HelpCtx; public class HierarchicalNodeLayoutAction extends AbstractCfgEditorAction { @Override public void performAction() { CfgEditorTopComponent tc = getEditor(); if (tc != null) { CfgScene scene = tc.getCfgScene(); scene.setSceneLayout(CfgEditorContext.LAYOUT_HIERARCHICALNODELAYOUT); scene.applyLayout(); } } public String getName() { return "Hierarchical Node Layout"; } @Override protected String iconResource() { return "at/ssw/visualizer/cfg/icons/arrangehier.gif"; } public HelpCtx getHelpCtx() { return HelpCtx.DEFAULT_HELP; } }