>无法抗拒,简单不同意答案JFrame frame = new JFrame();和frame.setVisible(true);
I want to open a new JFrame when the user hits the first calculate
button and serve as a Output window (Simlar to SPSS output windows if
you are familiar with them).
> don’t do that, create only two JFrames,重用第二名. JFrame使用getContentPane.removeAll(),来自JButton的其他操作
>那么所有生命周期都只是关于setVisible(true)/ setVisible(false)
>将DefaultCloseOperations更改为HIDE_ON_CLOSE
The New JFrame will be completely separate and will have its own menu
bar. A simple JDialog is not the way to go here.
> JDialog有什么问题,工具栏中只有一个按钮与JFrame中的三个按钮相比,简单不同意,
Output window (Simlar to SPSS output windows if you are familiar with
them).
>使用SwingWorker或Runnable #Thread(必需包装到invokeLater)获取放入JDialog的JComponents的值,如果所有更改都完成,则调用JDialog.setVisible(true)包装到invokeLater()中