Riaan Nel wrote:Look at line 108. You want to close the frame, but all you do is to make the components on your frame invisible. You need to dispose of the frame.
Something like this.
The PmtGui.this is used to tell your anonymous inner class (MouseAdapter) that you are referring to the outer class (PmtGui).
On a side note, don't use MouseListeners on buttons. If you disable the button, the MouseListener will still register events. Rather use an ActionListener.