this.direction = dir;
}
@Override
protected void run(Object selected, ActionEvent evt) {
NavigationOrder navigationOrder = graph.getNavigationOrder();
if (navigationOrder == null) {
return;
}
Object o = direction > 0 ? navigationOrder.next(selected) : navigationOrder.previous(selected);
if (o != null && o != selected) {
List<Object> newSelection = KongaListUtils.asList(o);
graph.getSelectionModel().setSelection(newSelection);
graph.getLayout().moveToTop(o);
graph.ensureNodeIsVisible(o);