티스토리 뷰

WindowListener windowListener = new WindowAdapter() {
    public void windowClosing(WindowEvent windowEvent) {
        System.out.println("Frame closed");
        windowEvent.getWindow().dispose();
    }
};

-----------
frame.addWindowListener(windowListener);
댓글
댓글쓰기 폼