This is for an assignment created in BlueJ and submitted as a zip file containing the BlueJ package.
In the package are several independent console programs. I am trying to create another "control panel" program - a gui with radio buttons to launch each program.
Here are 2 of the listener classes I have tried:
private class RadioButtonListener implements ActionListener
{
public void actionPerformed(ActionEvent e)
{
if(e.getSource() == arraySearchButton)
{
new ArraySearch();
}//end if
else if(e.getSource() == workerDemoButton)
{
new WorkerDemo();
}//end else if
}//end actionPerformed
}//end class RadioButtonListener
private class RunButtonListener implements ActionListener
{
public void actionPerformed(ActionEvent e)
{
if(arraySearchButton.isSelected())
{
new ArraySearch();
}//end if
else if(workerDemoButton.isSelected())
{
new WorkerDemo();
}//end else if
}//end actionPerformed
}//end class RunButtonListener
Thanks in advance!