use of org.eclipse.zest.core.widgets.GraphNode in project linuxtools by eclipse.
the class StapGraphMouseListener method controlDoubleClick.
private void controlDoubleClick() {
if (graph.getDrawMode() == StapGraph.CONSTANT_DRAWMODE_AGGREGATE) {
GraphNode node = getAggregateNodeFromSelection();
if (node == null) {
return;
}
// $NON-NLS-1$
String functionName = (String) node.getData("AGGREGATE_NAME");
FileFinderOpener.findAndOpen(graph.getProject(), functionName);
node.unhighlight();
} else {
StapNode node = getNodeFromSelection();
if (node == null) {
return;
}
int caller = node.getData().id;
if (caller < graph.getFirstUsefulNode()) {
// The only node that satisfies this condition should be main
caller = graph.getFirstUsefulNode();
}
FileFinderOpener.findAndOpen(graph.getProject(), graph.getNodeData(caller).name);
node.unhighlight();
}
graph.setSelection(null);
}
Aggregations