From 37abccaea2409929a679cb0c12289ba2082f6123 Mon Sep 17 00:00:00 2001 From: hades Date: Fri, 3 Sep 2021 11:05:56 +0800 Subject: [PATCH 1/2] =?UTF-8?q?REPORT-58713=20=E5=86=B3=E7=AD=96=E6=8A=A5?= =?UTF-8?q?=E8=A1=A8=E4=B8=AD=E5=85=AC=E5=BC=8F=E6=A8=A1=E6=8B=9F=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E7=9A=84=E5=8F=82=E6=95=B0=E7=BC=96=E8=BE=91=E7=AA=97?= =?UTF-8?q?=E5=8F=A3=E4=BC=9A=E5=87=BA=E7=8E=B0=E2=80=9C=E9=97=AA=E5=B1=8F?= =?UTF-8?q?=E2=80=9D=E7=8E=B0=E8=B1=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/fr/design/designer/creator/XCreator.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java index 55b9c191f..e0e6e74a4 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java @@ -802,7 +802,12 @@ public abstract class XCreator extends JPanel implements XComponent, XCreatorToo try { popup.setLocation(designer.getLocationOnScreen().x + designer.getPaintX() + extraX, designer.getLocationOnScreen().y + designer.getPaintY() + extraY); popup.updatePane(designer); - popup.setVisible(selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog()); + boolean needShowing = selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog(); + if (!popup.isVisible() && needShowing) { + popup.setVisible(true); + } else if (!needShowing) { + popup.setVisible(false); + } popup.setRelativeBounds(bounds); } catch (Exception ignored) { } From 98768ff1088b7541169523f4086883456259cb73 Mon Sep 17 00:00:00 2001 From: hades Date: Fri, 3 Sep 2021 11:44:46 +0800 Subject: [PATCH 2/2] =?UTF-8?q?REPORT-58713=20=20=E5=8A=A0=E4=BA=9B?= =?UTF-8?q?=E6=B3=A8=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/fr/design/designer/creator/XCreator.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java index e0e6e74a4..e82528558 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java @@ -803,6 +803,8 @@ public abstract class XCreator extends JPanel implements XComponent, XCreatorToo popup.setLocation(designer.getLocationOnScreen().x + designer.getPaintX() + extraX, designer.getLocationOnScreen().y + designer.getPaintY() + extraY); popup.updatePane(designer); boolean needShowing = selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog(); + // 当不可见时,且可以设置为可见状态,才去设置为可见 + // 避免已经是可见状态时,重复设置可见,造成闪屏 if (!popup.isVisible() && needShowing) { popup.setVisible(true); } else if (!needShowing) {