From 380cf6ab675a00ca975ac90de0cd8e39cf525d9a Mon Sep 17 00:00:00 2001 From: lucian Date: Tue, 12 Jan 2021 15:25:39 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-46892=20=E5=88=87=E6=8D=A2=E7=9B=AE?= =?UTF-8?q?=E5=BD=95=E6=9C=89=E6=8F=92=E4=BB=B6=E7=89=88=E6=9C=AC=E4=B8=8D?= =?UTF-8?q?=E5=8C=B9=E9=85=8D=E7=9B=AE=E5=BD=95=E9=85=8D=E7=BD=AE=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=98=BE=E7=A4=BA=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/fr/design/EnvChangeEntrance.java | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/EnvChangeEntrance.java b/designer-base/src/main/java/com/fr/design/EnvChangeEntrance.java index 6de15517ac..2b36bd45f1 100644 --- a/designer-base/src/main/java/com/fr/design/EnvChangeEntrance.java +++ b/designer-base/src/main/java/com/fr/design/EnvChangeEntrance.java @@ -310,9 +310,14 @@ public class EnvChangeEntrance { String content = PluginErrorRemindHandler.pluginErrorContent(); if (StringUtils.isNotEmpty(content)) { - SwingUtilities.invokeLater(() -> { - PluginErrorRemindDialog dialog = new PluginErrorRemindDialog(DesignerContext.getDesignerFrame(), content); - dialog.setVisible(true); + // 该操作需要在当前awt操作之后执行,使用SwingUtilities.invokeLater将其置于awt操作对列末尾 + // 若使用UIUtil.invokeLaterIfNeeded,会立即执行,影响其他UI操作 + SwingUtilities.invokeLater(new Runnable() { + @Override + public void run() { + PluginErrorRemindDialog dialog = new PluginErrorRemindDialog(DesignerContext.getDesignerFrame(), content); + dialog.setVisible(true); + } }); } }