From d1c3efd6a32f8d25880ef3019df2754cf0c9dbbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=B2=B3?= <445798420@qq.com> Date: Thu, 29 Oct 2020 16:54:26 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=09CHART-16369=20=E7=94=98=E7=89=B9?= =?UTF-8?q?=E5=9B=BE=E6=95=B0=E6=8D=AE=E7=82=B9=E6=9D=A1=E4=BB=B6=E5=B1=9E?= =?UTF-8?q?=E6=80=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gantt/designer/other/VanChartGanttConditionPane.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/designer-chart/src/main/java/com/fr/van/chart/gantt/designer/other/VanChartGanttConditionPane.java b/designer-chart/src/main/java/com/fr/van/chart/gantt/designer/other/VanChartGanttConditionPane.java index 09d7a4b81..fed1d799a 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/gantt/designer/other/VanChartGanttConditionPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/gantt/designer/other/VanChartGanttConditionPane.java @@ -19,6 +19,7 @@ import com.fr.van.chart.designer.style.tooltip.VanChartPlotTooltipNoCheckPane; import com.fr.van.chart.designer.style.tooltip.VanChartPlotTooltipPane; import com.fr.van.chart.gantt.designer.style.label.VanChartGanttLabelConditionPane; +import javax.swing.JPanel; import java.awt.Dimension; /** @@ -55,6 +56,11 @@ public class VanChartGanttConditionPane extends DataSeriesConditionPane { ((AttrGanttTooltipContent) attrGanttTooltip.getContent()).getDurationFormat().setEnable(true); return attrGanttTooltip; } + + @Override + protected JPanel createDisplayStrategy(Plot plot) { + return null; + } }; } From c63e6468ec4e6b9156891d49415d3379328bb251 Mon Sep 17 00:00:00 2001 From: hades Date: Thu, 29 Oct 2020 17:29:49 +0800 Subject: [PATCH 2/3] =?UTF-8?q?REPORT-40971=20=E6=B7=BB=E5=8A=A0=E6=9D=A1?= =?UTF-8?q?=E4=BB=B6=E5=B1=9E=E6=80=A7=E9=80=89=E6=8B=A9=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E5=88=97=EF=BC=8C=E9=80=89=E9=A1=B9=E4=B8=AD=E7=9A=84=E6=A8=A1?= =?UTF-8?q?=E6=9D=BF=E6=95=B0=E6=8D=AE=E9=9B=86=E4=BC=9A=E6=98=AF=E5=88=AB?= =?UTF-8?q?=E7=9A=84=E6=A8=A1=E6=9D=BF=E7=9A=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../condition/ObjectLiteConditionPane.java | 2 +- .../design/editor/ValueEditorPaneFactory.java | 38 ++++++++++++++++++- .../editor/editor/ColumnSelectedEditor.java | 8 +++- 3 files changed, 44 insertions(+), 4 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/condition/ObjectLiteConditionPane.java b/designer-base/src/main/java/com/fr/design/condition/ObjectLiteConditionPane.java index b863717f6..c39d5b744 100644 --- a/designer-base/src/main/java/com/fr/design/condition/ObjectLiteConditionPane.java +++ b/designer-base/src/main/java/com/fr/design/condition/ObjectLiteConditionPane.java @@ -77,7 +77,7 @@ public class ObjectLiteConditionPane extends LiteConditionPane } }); - conditionValuePane = ValueEditorPaneFactory.createAllValueEditorPane(); + conditionValuePane = ValueEditorPaneFactory.createAllValueEditorPaneWithGlobalListener(); Component[][] components = { { new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_ConditionB_Operator") + ":"), new UILabel() }, { conditionOPComboBox, conditionValuePane } }; diff --git a/designer-base/src/main/java/com/fr/design/editor/ValueEditorPaneFactory.java b/designer-base/src/main/java/com/fr/design/editor/ValueEditorPaneFactory.java index 71959b72d..462292099 100644 --- a/designer-base/src/main/java/com/fr/design/editor/ValueEditorPaneFactory.java +++ b/designer-base/src/main/java/com/fr/design/editor/ValueEditorPaneFactory.java @@ -19,17 +19,18 @@ import com.fr.design.editor.editor.TextEditor; import com.fr.design.editor.editor.WidgetNameEditor; import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.itableeditorpane.ParameterTableModel; +import com.fr.design.i18n.Toolkit; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.stable.StringUtils; -import javax.swing.*; -import java.awt.*; +import java.awt.BorderLayout; import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; +import javax.swing.JPanel; public class ValueEditorPaneFactory { @@ -155,6 +156,16 @@ public class ValueEditorPaneFactory { return createValueEditorPane(allEditors(), StringUtils.EMPTY, StringUtils.EMPTY); } + /** + * 带有所有编辑器的ValueEditorPane + * 同时需要注册全局监听的编辑器注册下监听 + * + * @return 值编辑器面板 + */ + public static ValueEditorPane createAllValueEditorPaneWithGlobalListener() { + return createValueEditorPane(allEditorsWithGlobalListener(), StringUtils.EMPTY, StringUtils.EMPTY); + } + /** * 创建不带公式面板的pane * @@ -359,6 +370,29 @@ public class ValueEditorPaneFactory { }; } + /** + * 所有类型的编辑器 + * 同时注册需要的监听 + * + * @return 值编辑器 + */ + public static Editor[] allEditorsWithGlobalListener() { + FormulaEditor formulaEditor = new FormulaEditor(Toolkit.i18nText("Fine-Design_Basic_Parameter_Formula")); + ColumnSelectedEditor columnSelectedEditor = new ColumnSelectedEditor(); + columnSelectedEditor.registerDSChangeListener(); + return new Editor[]{ + new TextEditor(), + new IntegerEditor(), + new DoubleEditor(), + new DateEditor(true, Toolkit.i18nText("Fine-Design_Basic_Date")), + new BooleanEditor(), + formulaEditor, + new ParameterEditor(), + new ColumnRowEditor(Toolkit.i18nText("Fine-Design_Basic_Cell")), + columnSelectedEditor, + }; + } + /** * 不带公式编辑器 * diff --git a/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java b/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java index ade55ae8b..5260ce175 100644 --- a/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java +++ b/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java @@ -3,6 +3,7 @@ package com.fr.design.editor.editor; import com.fr.design.data.DesignTableDataManager; import com.fr.data.SimpleDSColumn; import com.fr.design.data.datapane.TableDataComboBox; +import com.fr.design.data.tabledata.Prepare4DataSourceChange; import com.fr.design.data.tabledata.wrapper.TableDataWrapper; import com.fr.design.gui.icombobox.UIComboBox; import com.fr.design.layout.FRGUIPaneFactory; @@ -22,7 +23,7 @@ import java.util.regex.Pattern; * @author zhou * @since 2012-3-29下午6:05:08 */ -public class ColumnSelectedEditor extends Editor { +public class ColumnSelectedEditor extends Editor implements Prepare4DataSourceChange { TableDataComboBox tableDataComboBox; private UIComboBox columnNameComboBox; protected String[] columnNames; @@ -107,4 +108,9 @@ public class ColumnSelectedEditor extends Editor { tableDataComboBox.setSelectedItem(null); columnNameComboBox.setSelectedItem(null); } + + @Override + public void registerDSChangeListener() { + tableDataComboBox.registerGlobalDSChangeListener(); + } } From 83051ae8c38d48202bccb16a1368023ab1de4081 Mon Sep 17 00:00:00 2001 From: "Qinghui.Liu" Date: Fri, 30 Oct 2020 16:36:28 +0800 Subject: [PATCH 3/3] =?UTF-8?q?CHART-16481=20=E5=A2=9E=E5=8A=A0=E7=A9=BA?= =?UTF-8?q?=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../designer/style/axis/VanChartBaseAxisPane.java | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java index a373dc445..8375086a9 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java @@ -591,13 +591,15 @@ public class VanChartBaseAxisPane extends FurtherBasicBeanPane { } protected void checkLabelGapPane() { - boolean visible = true; + if (labelGapPane != null) { + boolean visible = true; - if (showLabelDisplay() && labelDisplayPane != null && labelDisplayComboBox != null) { - visible = labelDisplayComboBox.getSelectedIndex() == 0; - } + if (showLabelDisplay() && labelDisplayPane != null && labelDisplayComboBox != null) { + visible = labelDisplayComboBox.getSelectedIndex() == 0; + } - labelGapPane.setVisible(visible); + labelGapPane.setVisible(visible); + } } protected void checkLabelGapValuePane() {