I have created two classes. One is my main GUI the other is my popup GUI which is launced via a button click.
How ever when i click the close button on my popup GUI it closes all the JFrames.
Here is my main GUI
public FirstAid() {
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setBounds(100, 100, 700, 507);
contentPane = new JPanel();
contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
setContentPane(contentPane);
contentPane.setLayout(new BorderLayout(0, 0));
My popup GUI also has the
EXIT_ON_CLOSE