@ -646,11 +646,7 @@ public class PreferencePane extends BasicPane {
if (l != null) {
dg.addDialogActionListener(l);
}
dg.setBasicDialogSize(BasicDialog.DEFAULT);
GUICoreUtils.centerWindow(dg);
dg.setResizable(false);
return dg;
return showWindow(dg);
private class DIALOG extends BasicDialog {
@ -39,11 +39,11 @@ public abstract class BasicDialog extends UIDialog {
super(parent, pane, isNeedButtonPane);
public void setBasicDialogSize(Dimension d) {
protected void setBasicDialogSize(Dimension d) {
super.setSize(d.width, d.height);
public void setBasicDialogSize(int w, int h) {
protected void setBasicDialogSize(int w, int h) {
super.setSize(w, h);
@ -52,6 +52,19 @@ public abstract class BasicPane extends JPanel {
/**
* 显示窗口
*
* @param dg 已添加监听器的对话框实例
* @return 对话框
*/
public BasicDialog showWindow(BasicDialog dg) {