From b5acdf4ac5531656178a2547605ec4522879c153 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=B2=B3?= <445798420@qq.com> Date: Thu, 19 Mar 2020 10:45:26 +0800 Subject: [PATCH] =?UTF-8?q?CHART-12820=20=E5=9C=B0=E5=9B=BE=E8=BE=B9?= =?UTF-8?q?=E7=95=8C=E4=B8=A2=E5=A4=B1=20&&=20CHART-13035=20=E9=92=BB?= =?UTF-8?q?=E5=8F=96=E5=9C=B0=E5=9B=BE=E4=B8=8B=E6=8B=89=E5=8C=B9=E9=85=8D?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/fr/design/chartx/component/MatchAreaTable.java | 5 ++++- .../com/fr/design/chartx/component/TableTreeComboBox.java | 4 ++-- .../com/fr/design/mainframe/chart/gui/type/MapPlotPane.java | 4 ++++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/design/chartx/component/MatchAreaTable.java b/designer-chart/src/main/java/com/fr/design/chartx/component/MatchAreaTable.java index 72ca947fdc..f4cdd84e0f 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/component/MatchAreaTable.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/component/MatchAreaTable.java @@ -4,6 +4,7 @@ import com.fr.design.gui.ilable.UILabel; import com.fr.design.i18n.Toolkit; import com.fr.general.GeneralUtils; import com.fr.plugin.chart.map.server.ChartGEOJSONHelper; +import com.fr.stable.StringUtils; import javax.swing.AbstractCellEditor; import javax.swing.JTable; @@ -113,7 +114,9 @@ public class MatchAreaTable extends JTable { } private void initComboBox(Object value, boolean editor) { - comboBox = new TableTreeComboBox(new JTree(root)); + //地图不显示第一层,钻取地图显示第一层。 + boolean showRoot = root.getUserObject() !=null && StringUtils.isNotEmpty(root.getUserObject().toString()); + comboBox = new TableTreeComboBox(new JTree(root),showRoot); comboBox.setEditable(true); comboBox.setSelectedItem(value); diff --git a/designer-chart/src/main/java/com/fr/design/chartx/component/TableTreeComboBox.java b/designer-chart/src/main/java/com/fr/design/chartx/component/TableTreeComboBox.java index e8f02984f2..97426e4c73 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/component/TableTreeComboBox.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/component/TableTreeComboBox.java @@ -32,8 +32,8 @@ public class TableTreeComboBox extends FRTreeComboBox { private JTextField textField; - public TableTreeComboBox(JTree tree) { - super(tree, null); + public TableTreeComboBox(JTree tree, boolean showRoot) { + super(tree, null, showRoot, false); textField = (JTextField) (this.getEditor().getEditorComponent()); textField.addKeyListener(treeKeyListener); tree.setCellRenderer(tableNameTreeRenderer); diff --git a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/MapPlotPane.java b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/MapPlotPane.java index 9880739265..96cae8b43f 100644 --- a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/MapPlotPane.java +++ b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/MapPlotPane.java @@ -67,6 +67,10 @@ public class MapPlotPane extends AbstractDeprecatedChartTypePane { return new String[0]; } + public void reLayout(String chartID) { + + } + /** * 界面标题 * @return 界面标题