if (aborting) { experimentFinished(); aborting = false; } else if (haveMoreTrials()) {
if (haveMoreTrials()) {
  public void nodeStopped(NodeComponent nodeComponent) {    oldNodes.put(nodeComponent, runningNodes.get(nodeComponent));    runningNodes.remove(nodeComponent);    // when any node has stopped, kill the rest of the nodes    // unless we're already killing the other nodes    if (!stopping)       stopAllNodes();    // when all nodes have stopped, save results    // run the next trial and update the gui controls    if (runningNodes.isEmpty()) {      stopping = false;      trialFinished();      if (aborting) {	experimentFinished();	aborting = false;      } else if (haveMoreTrials()) {	if (!userStoppedTrials) {	  destroyOldNodes(); // destroy old guis before starting new ones	  runTrial(); // run next trial	} else { // user stopped trials, allow them to run the next one	  runButton.setSelected(false);	}      } else { // no more trials, experiment is done	experimentFinished();      }    }  }