updateExperimentControls(experiment, false);  experiment.setRunInProgress(false);
updateControls(false); if (experiment != null) experiment.setRunInProgress(false);
  private void exitMenuItem_actionPerformed(AWTEvent e) {    stopExperiments();    updateExperimentControls(experiment, false);    //    updateExperimentEditability();    experiment.setRunInProgress(false);    // If this was this frame's exit menu item, we have to remove    // the window from the list    // if it was a WindowClose, the parent notices this as well    if (e instanceof ActionEvent)      NamedFrame.getNamedFrame().removeFrame(this);    dispose();  }