Browse Source

Pull request #2220: REPORT-38647 【回归】新建表单,进行一些操作之后,右侧组件不显示了 && REPORT-38357 设计器面板新建文件夹显示问题

Merge in DESIGN/design from ~HADES/design:feature/10.0 to feature/10.0

* commit 'f1b091ce26c9a09f508a43a992131f47a1d6197b':
  REPORT-38647 && REPORT-38357
persist/11.0
Hades 4 years ago
parent
commit
866e24cbb8
  1. 2
      designer-base/src/main/java/com/fr/design/mainframe/DesignerFrameFileDealerPane.java
  2. 8
      designer-form/src/main/java/com/fr/design/designer/treeview/ComponentTreeCellRenderer.java

2
designer-base/src/main/java/com/fr/design/mainframe/DesignerFrameFileDealerPane.java

@ -856,7 +856,7 @@ public class DesignerFrameFileDealerPane extends JPanel implements FileToolbarSt
BorderLayout.CENTER);
this.setSize(340, 180);
this.setSize(380, 180);
this.setTitle(Toolkit.i18nText("Fine-Design_Basic_Mkdir"));
this.setResizable(false);
this.setAlwaysOnTop(true);

8
designer-form/src/main/java/com/fr/design/designer/treeview/ComponentTreeCellRenderer.java

@ -4,6 +4,7 @@ import com.fr.design.constants.UIConstants;
import com.fr.design.designer.creator.XCreator;
import com.fr.design.designer.creator.XCreatorUtils;
import com.fr.design.gui.ilable.UILabel;
import com.fr.log.FineLoggerFactory;
import javax.swing.Icon;
import javax.swing.JTree;
@ -23,7 +24,12 @@ public class ComponentTreeCellRenderer extends DefaultTreeCellRenderer {
if (value instanceof XCreator) {
String name = ((XCreator) value).toData().getWidgetName();
setText(name);
Icon icon = XCreatorUtils.getCreatorIcon((XCreator) value);
Icon icon = null;
try {
icon = XCreatorUtils.getCreatorIcon((XCreator) value);
} catch (Exception e) {
FineLoggerFactory.getLogger().info("{} has not icon or has been deleted", name);
}
if (icon != null) {
setIcon(icon);
}

Loading…
Cancel
Save