From 77d9207fc4b0a43870f76c02acfc88555a52d591 Mon Sep 17 00:00:00 2001 From: zheng Date: Tue, 25 Jun 2019 19:42:41 +0800 Subject: [PATCH] xchart rename to chartProvider --- .../java/com/fr/design/gui/chart/MiddleChartComponent.java | 4 ++-- .../main/java/com/fr/design/ChartTypeInterfaceManager.java | 4 ++-- .../src/main/java/com/fr/design/chart/ChartTypePane.java | 6 +++--- .../main/java/com/fr/design/chart/gui/ChartComponent.java | 4 ++-- .../java/com/fr/design/chart/gui/ChartWidgetOption.java | 6 +++--- .../series/SeriesCondition/impl/ChartHyperPoplinkPane.java | 6 +++--- .../fr/design/mainframe/chart/gui/ChartTypeButtonPane.java | 6 +++--- .../mainframe/chart/gui/type/AbstractChartTypePane.java | 4 ++-- .../main/java/com/fr/extended/chart/ExtendedTypePane.java | 4 ++-- 9 files changed, 22 insertions(+), 22 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/gui/chart/MiddleChartComponent.java b/designer-base/src/main/java/com/fr/design/gui/chart/MiddleChartComponent.java index 025c669bc..01d9e7dd3 100644 --- a/designer-base/src/main/java/com/fr/design/gui/chart/MiddleChartComponent.java +++ b/designer-base/src/main/java/com/fr/design/gui/chart/MiddleChartComponent.java @@ -1,7 +1,7 @@ package com.fr.design.gui.chart; import com.fr.base.chart.BaseChartCollection; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.stable.core.PropertyChangeListener; import javax.swing.JComponent; @@ -18,7 +18,7 @@ public abstract class MiddleChartComponent extends JComponent { public abstract void reset(); - public abstract XChart getEditingChart(); + public abstract ChartProvider getEditingChart(); public abstract void addStopEditingListener(PropertyChangeListener list); } \ No newline at end of file diff --git a/designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java b/designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java index a188737c0..72585ade8 100644 --- a/designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java +++ b/designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java @@ -5,7 +5,7 @@ import com.fr.chart.base.ChartInternationalNameContentBean; import com.fr.chart.chartattr.Chart; import com.fr.chart.chartattr.Plot; import com.fr.chart.charttypes.ChartTypeManager; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.beans.BasicBeanPane; import com.fr.design.beans.FurtherBasicBeanPane; import com.fr.design.chart.fun.IndependentChartUIProvider; @@ -162,7 +162,7 @@ public class ChartTypeInterfaceManager implements ExtraChartDesignClassManagerPr int index = 0; for (ChartInternationalNameContentBean bean : typeName) { String plotID = bean.getPlotID(); - XChart[] rowChart = ChartTypeManager.getInstance().getChartTypes(plotID); + ChartProvider[] rowChart = ChartTypeManager.getInstance().getChartTypes(plotID); if (ArrayUtils.isEmpty(rowChart) && !ChartTypeManager.innerChart(plotID)) { continue; } diff --git a/designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java b/designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java index ed1e2656e..2a19072e0 100644 --- a/designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java +++ b/designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java @@ -11,7 +11,7 @@ import com.fr.chart.chartattr.ChartIcon; import com.fr.chart.chartattr.MapPlot; import com.fr.chart.chartattr.Plot; import com.fr.chart.charttypes.ChartTypeManager; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.gui.ilable.UILabel; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.utils.gui.GUICoreUtils; @@ -43,7 +43,7 @@ public class ChartTypePane extends ChartCommonWizardPane { { charts4Icon = new Chart[this.typeName.length][]; for (int i = 0; i < this.typeName.length; i++) { - XChart[] rowCharts = ChartTypeManager.getInstanceWithCheck().getChartTypes(this.typeName[i].getPlotID()); + ChartProvider[] rowCharts = ChartTypeManager.getInstanceWithCheck().getChartTypes(this.typeName[i].getPlotID()); int rowChartsCount = rowCharts.length; charts4Icon[i] = new Chart[rowChartsCount]; for (int j = 0; j < rowChartsCount; j++) { @@ -147,7 +147,7 @@ public class ChartTypePane extends ChartCommonWizardPane { int subIndex = 0; for (int i = 0; i < typeName.length; i++) { - XChart[] charts = ChartTypeManager.getInstanceWithCheck().getChartTypes(typeName[i].getPlotID()); + ChartProvider[] charts = ChartTypeManager.getInstanceWithCheck().getChartTypes(typeName[i].getPlotID()); for (int j = 0; j < charts.length; j++) { if (((Chart) charts[j]).getPlot().match4GUI(plot)) { mainIndex = i; diff --git a/designer-chart/src/main/java/com/fr/design/chart/gui/ChartComponent.java b/designer-chart/src/main/java/com/fr/design/chart/gui/ChartComponent.java index 85fcaaeff..31baca071 100644 --- a/designer-chart/src/main/java/com/fr/design/chart/gui/ChartComponent.java +++ b/designer-chart/src/main/java/com/fr/design/chart/gui/ChartComponent.java @@ -9,7 +9,7 @@ import com.fr.chart.chartattr.Axis; import com.fr.chart.chartattr.Chart; import com.fr.chart.chartattr.ChartCollection; import com.fr.chart.chartglyph.AxisGlyph; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.chart.gui.active.ActiveGlyph; import com.fr.design.chart.gui.active.ChartActiveGlyph; import com.fr.design.file.HistoryTemplateListPane; @@ -162,7 +162,7 @@ public class ChartComponent extends MiddleChartComponent implements MouseListene return (this.chartCollection4Design == null) ? 0 : this.chartCollection4Design.getChartCount(); } - public XChart getEditingChart() { + public ChartProvider getEditingChart() { return editingChart; } diff --git a/designer-chart/src/main/java/com/fr/design/chart/gui/ChartWidgetOption.java b/designer-chart/src/main/java/com/fr/design/chart/gui/ChartWidgetOption.java index d52dcbfde..eb36aadea 100644 --- a/designer-chart/src/main/java/com/fr/design/chart/gui/ChartWidgetOption.java +++ b/designer-chart/src/main/java/com/fr/design/chart/gui/ChartWidgetOption.java @@ -1,7 +1,7 @@ package com.fr.design.chart.gui; import com.fr.chart.charttypes.ChartTypeManager; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.gui.core.WidgetOption; import com.fr.form.ui.ChartEditor; import com.fr.form.ui.Widget; @@ -38,8 +38,8 @@ public class ChartWidgetOption extends WidgetOption { Class clz = widgetClass(); try { ChartEditor widget = clz.newInstance(); - XChart chart = ChartTypeManager.getInstanceWithCheck().getChartTypes(this.chartID)[0]; - widget.addChart((XChart) chart.clone()); + ChartProvider chart = ChartTypeManager.getInstanceWithCheck().getChartTypes(this.chartID)[0]; + widget.addChart((ChartProvider) chart.clone()); return widget; } catch (InstantiationException e) { FineLoggerFactory.getLogger().error(e.getMessage(), e); diff --git a/designer-chart/src/main/java/com/fr/design/chart/series/SeriesCondition/impl/ChartHyperPoplinkPane.java b/designer-chart/src/main/java/com/fr/design/chart/series/SeriesCondition/impl/ChartHyperPoplinkPane.java index 01c5a156e..74c78ff2d 100644 --- a/designer-chart/src/main/java/com/fr/design/chart/series/SeriesCondition/impl/ChartHyperPoplinkPane.java +++ b/designer-chart/src/main/java/com/fr/design/chart/series/SeriesCondition/impl/ChartHyperPoplinkPane.java @@ -6,7 +6,7 @@ import com.fr.chart.chartattr.Chart; import com.fr.chart.chartattr.ChartCollection; import com.fr.chart.charttypes.ChartTypeManager; import com.fr.chart.web.ChartHyperPoplink; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.chart.gui.ChartComponent; import com.fr.design.gui.itextfield.UITextField; import com.fr.design.hyperlink.AbstractHyperLinkPane; @@ -67,10 +67,10 @@ public class ChartHyperPoplinkPane extends AbstractHyperLinkPane implemen if (editingCollection != null) { //点击添加按钮,则会触发切换状态 - XChart chart = editingCollection.getChangeStateNewChart(); + ChartProvider chart = editingCollection.getChangeStateNewChart(); try { - XChart newChart = (XChart) chart.clone(); + ChartProvider newChart = (ChartProvider) chart.clone(); editingCollection.addNamedChart(name, newChart); } catch (CloneNotSupportedException e1) { FineLoggerFactory.getLogger().error("Error in Clone"); diff --git a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/AbstractChartTypePane.java b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/AbstractChartTypePane.java index 46447495d..47de03b56 100644 --- a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/AbstractChartTypePane.java +++ b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/AbstractChartTypePane.java @@ -17,7 +17,7 @@ import com.fr.chart.chartattr.Plot; import com.fr.chart.chartattr.Title; import com.fr.chart.chartglyph.ConditionAttr; import com.fr.chart.charttypes.BarIndependentChart; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.beans.FurtherBasicBeanPane; import com.fr.design.chart.series.PlotStyle.ChartSelectDemoPane; import com.fr.design.gui.ilable.BoldFontTextLabel; @@ -617,7 +617,7 @@ public abstract class AbstractChartTypePane extends FurtherBasicBeanPane{ return typePane; } - public XChart getDefaultChart() { + public ChartProvider getDefaultChart() { return BarIndependentChart.barChartTypes[0]; } } \ No newline at end of file diff --git a/designer-chart/src/main/java/com/fr/extended/chart/ExtendedTypePane.java b/designer-chart/src/main/java/com/fr/extended/chart/ExtendedTypePane.java index 331e51164..ccc39b525 100644 --- a/designer-chart/src/main/java/com/fr/extended/chart/ExtendedTypePane.java +++ b/designer-chart/src/main/java/com/fr/extended/chart/ExtendedTypePane.java @@ -2,7 +2,7 @@ package com.fr.extended.chart; import com.fr.chart.chartattr.Chart; import com.fr.chart.charttypes.ChartTypeManager; -import com.fr.chartx.attr.XChart; +import com.fr.chartx.attr.ChartProvider; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; import com.fr.design.mainframe.chart.gui.type.ChartImagePane; @@ -66,7 +66,7 @@ public class ExtendedTypePane extends AbstractChartType } @Override - public XChart getDefaultChart() { + public ChartProvider getDefaultChart() { return ChartTypeManager.getInstance().getChartTypes(getPlotID())[0]; }