use of org.absmodels.abs.plugin.util.UtilityFunctions.EditorPosition in project abstools by abstools.
the class TypeHierarchyView method doubleClick.
@Override
public void doubleClick(DoubleClickEvent event) {
// when an element is doubleclicked, jump to its declaration
ISelection selected = treeViewer.getSelection();
if (selected instanceof TreeSelection) {
TreeSelection treeSelection = (TreeSelection) selected;
Object elem = treeSelection.getFirstElement();
if (elem instanceof ASTNode<?>) {
ASTNode<?> node = (ASTNode<?>) elem;
EditorPosition pos = AbsHyperlinkDetector.getPosition(node);
UtilityFunctions.jumpToPosition(project, pos);
}
}
}
Aggregations