From d27fbb50d19faba3e5815d40f13fb1f3ab70b7e7 Mon Sep 17 00:00:00 2001 From: plough Date: Tue, 12 Sep 2017 16:09:55 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-4421=20=E4=BB=A5=E4=B8=8B=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E6=9C=AA=E7=94=9F=E6=88=90=E9=97=AE=E9=A2=98=3D>?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=A9=BA=E6=8C=87=E9=92=88=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/parameter/ParameterPropertyPane.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/designer_form/src/com/fr/design/parameter/ParameterPropertyPane.java b/designer_form/src/com/fr/design/parameter/ParameterPropertyPane.java index 629af593f..31d864157 100644 --- a/designer_form/src/com/fr/design/parameter/ParameterPropertyPane.java +++ b/designer_form/src/com/fr/design/parameter/ParameterPropertyPane.java @@ -90,8 +90,13 @@ public class ParameterPropertyPane extends JPanel{ return; } // 表单中,只有添加并选中参数面板时,才显示 - boolean hideInJForm = DesignerContext.getDesignerFrame().getSelectedJTemplate() instanceof JForm && - !(FormHierarchyTreePane.getInstance().getComponentTree().getSelectionPath().getLastPathComponent() instanceof XWParameterLayout); + boolean hideInJForm; + try { + hideInJForm = DesignerContext.getDesignerFrame().getSelectedJTemplate() instanceof JForm && + !(FormHierarchyTreePane.getInstance().getComponentTree().getSelectionPath().getLastPathComponent() instanceof XWParameterLayout); + } catch (NullPointerException ex) { + hideInJForm = false; + } if (isVisible && toolbarPane.hasSelectedLabelItem() && !hideInJForm) { addParaPane.setVisible(true); this.setPreferredSize(null);