From 6ae8ef494ef9e6d8fac1c5730d22b3327baaffd6 Mon Sep 17 00:00:00 2001 From: Harrison Date: Fri, 22 May 2020 16:58:03 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-32162=20=E6=9B=BF=E6=8D=A2=20ui=20?= =?UTF-8?q?=E7=9A=84=E6=97=B6=E5=80=99=EF=BC=8C=E9=9C=80=E8=A6=81=E5=9C=A8?= =?UTF-8?q?=E4=BA=8B=E4=BB=B6=E5=88=86=E5=8F=91=E7=BA=BF=E7=A8=8B=E4=B8=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mainframe/EastRegionContainerPane.java | 22 ++++++++++++------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/EastRegionContainerPane.java b/designer-base/src/main/java/com/fr/design/mainframe/EastRegionContainerPane.java index 622e9a59cb..394dfca1e2 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/EastRegionContainerPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/EastRegionContainerPane.java @@ -485,24 +485,30 @@ public class EastRegionContainerPane extends UIEastResizableContainer { public void replaceAuthorityEditionPane(JComponent pane) { propertyItemMap.get(KEY_AUTHORITY_EDITION).replaceContentPane(pane); } - + public JComponent getAuthorityEditionPane() { return propertyItemMap.get(KEY_AUTHORITY_EDITION).getContentPane(); } - + public void replaceConfiguredRolesPane(JComponent pane) { propertyItemMap.get(KEY_CONFIGURED_ROLES).replaceContentPane(pane); } - - public void replaceKeyPane(String key, JComponent pane) { - - propertyItemMap.get(key).replaceContentPane(pane); + + public void replaceKeyPane(final String key, final JComponent pane) { + + //需要放到 ui 线程中处理 + UIUtil.invokeLaterIfNeeded(new Runnable() { + @Override + public void run() { + propertyItemMap.get(key).replaceContentPane(pane); + } + }); } - + public JComponent getConfiguredRolesPane() { return propertyItemMap.get(KEY_CONFIGURED_ROLES).getContentPane(); } - + public void addParameterPane(JComponent paraPane) { propertyItemMap.get(KEY_WIDGET_SETTINGS).replaceHeaderPane(paraPane); }