Browse Source

REPORT-98932 设计器拖动至屏幕外时触发弹出框后无法进行操作

release/11.0
obo 1 year ago
parent
commit
ee26d574f3
  1. 11
      designer-base/src/main/java/com/fr/design/style/color/ColorSelectDialog.java

11
designer-base/src/main/java/com/fr/design/style/color/ColorSelectDialog.java

@ -7,6 +7,11 @@ import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.utils.gui.GUICoreUtils; import com.fr.design.utils.gui.GUICoreUtils;
import javax.swing.JPanel; import javax.swing.JPanel;
import javax.swing.SwingUtilities;
import java.awt.Point;
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;
import java.awt.event.KeyListener;
import java.io.Serializable; import java.io.Serializable;
import java.awt.BorderLayout; import java.awt.BorderLayout;
import java.awt.Color; import java.awt.Color;
@ -79,6 +84,7 @@ public class ColorSelectDialog extends MiddleChartDialog{
this.seletePane = seletePane; this.seletePane = seletePane;
initComponent(); initComponent();
this.pane.populate(initialColor); this.pane.populate(initialColor);
this.setLocationRelativeTo(null);
} }
private void initComponent() { private void initComponent() {
@ -87,7 +93,8 @@ public class ColorSelectDialog extends MiddleChartDialog{
this.setBasicDialogSize(545,500); this.setBasicDialogSize(545,500);
this.setResizable(false); this.setResizable(false);
this.applyClosingAction();
this.applyEscapeAction();
JPanel buttonPane = new JPanel(); JPanel buttonPane = new JPanel();
buttonPane.setLayout(new FlowLayout(FlowLayout.RIGHT)); buttonPane.setLayout(new FlowLayout(FlowLayout.RIGHT));
@ -148,7 +155,7 @@ public class ColorSelectDialog extends MiddleChartDialog{
ColorSelectDialog dialog = new ColorSelectDialog(owner,pane,initialColor,okListener,selectePane); ColorSelectDialog dialog = new ColorSelectDialog(owner,pane,initialColor,okListener,selectePane);
dialog.setAlwaysOnTop(alwaysOnTop); dialog.setAlwaysOnTop(alwaysOnTop);
dialog.setModal(true); dialog.setModal(true);
dialog.show(); dialog.setVisible(true);
} }
/** /**

Loading…
Cancel
Save