Is it possible to close parent element of a component .. probably a JFrame
/JInternalFrame
from a JPanel? if yes how it can be done?
This will help you:
SwingUtilities.windowForComponent(panel).dispose();
or
SwingUtilities.windowForComponent(panel).setVisible(false);