Answer the question
In order to leave comments, you need to log in
What command will allow you to close a separate frame instead of an application?
Hello, masters) I'm still learning, I ask for advice.
Everyone knows that setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE) terminates the application when the frame is closed.
But I have such a moment: the mine-window has an "Options" button in it. When you click on it, a window with application settings appears. There, of course, I will make an exit button, like "Done", but .. what should I write in it? And in the body of the Options window class itself there is a line setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE) which kills the entire application completely if the options are closed. How to solve this problem? How to close a separate Options window when returning to the main application?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question