/** * Switches to the simple setup mode only if allowed to. * * @param exp the experiment to configure */ public void switchToSimple(Experiment exp) { if (exp == null) { exp = m_advancedPanel.getExperiment(); } if (exp != null && !m_simplePanel.setExperiment(exp)) { m_AdvancedSetupRBut.setSelected(true); switchToAdvanced(exp); } else { remove(m_advancedPanel); m_advancedPanel.removeNotesFrame(); add(m_simplePanel, BorderLayout.CENTER); validate(); repaint(); } }
/** * Gets the currently configured experiment. * * @return the currently configured experiment. */ public Experiment getExperiment() { if (m_SimpleSetupRBut.isSelected()) return m_simplePanel.getExperiment(); else return m_advancedPanel.getExperiment(); }