Browse Source

Pull request #4515: REPORT-53592 扩展图表创建共享组件npe问题

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

* commit '3af622275391f496956161d41650569a460a6299':
  REPORT-53592 扩展图表创建共享组件npe问题
  REPORT-52539 window上生成面板出现了滚动条
  REPORT-53592 扩展图表创建共享组件npe问题
feature/10.0
Tommy 3 years ago
parent
commit
9094d90149
  1. 10
      designer-realize/src/main/java/com/fr/design/share/effect/EffectItemGroup.java
  2. 4
      designer-realize/src/main/java/com/fr/design/share/ui/generate/EffectContent.java
  3. 2
      designer-realize/src/main/java/com/fr/design/share/ui/generate/ShareGeneratePane.java

10
designer-realize/src/main/java/com/fr/design/share/effect/EffectItemGroup.java

@ -111,8 +111,11 @@ public class EffectItemGroup {
ChartCollection chartCollection = (ChartCollection) value;
for (int index = 0; index < chartCollection.getChartCount(); index++) {
Chart chart= (Chart) chartCollection.getChart(index, ChartProvider.class);
SourceNode chartSourceNode = SourceNodeUtils.createSourceNode(chart.getPlot(), chartCollection.getChartName(index), cellSourceNode);
Plot plot = chart.getPlot();
if (plot == null) {
continue;
}
SourceNode chartSourceNode = SourceNodeUtils.createSourceNode(plot, chartCollection.getChartName(index), cellSourceNode);
initChartPlot(plot, chartSourceNode, false);
}
@ -126,8 +129,11 @@ public class EffectItemGroup {
ChartCollection chartCollection = (ChartCollection) editor.getChartCollection();
for (int index = 0; index < chartCollection.getChartCount(); index++) {
Chart chart= (Chart) chartCollection.getChart(index, ChartProvider.class);
SourceNode plotSourceNode = SourceNodeUtils.createSourceNode(chart.getPlot(), chartCollection.getChartName(index), null);
Plot plot = chart.getPlot();
if (plot == null) {
continue;
}
SourceNode plotSourceNode = SourceNodeUtils.createSourceNode(plot, chartCollection.getChartName(index), null);
initChartPlot(plot, plotSourceNode, false);
}

4
designer-realize/src/main/java/com/fr/design/share/ui/generate/EffectContent.java

@ -56,8 +56,8 @@ public class EffectContent extends JPanel {
Object[] columnNames = {com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Share_From"), com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Share_Rename")};
JTable table = new JTable(new EffectTableModel(effectItemGroup, columnNames));
table.setRowHeight(25);
table.getColumnModel().getColumn(0).setPreferredWidth(235);
table.getColumnModel().getColumn(1).setPreferredWidth(325);
table.getColumnModel().getColumn(0).setPreferredWidth(230);
table.getColumnModel().getColumn(1).setPreferredWidth(320);
table.setDefaultEditor(EffectTableModel.class, new EffectItemEditor(table));

2
designer-realize/src/main/java/com/fr/design/share/ui/generate/ShareGeneratePane.java

@ -62,7 +62,7 @@ import static javax.swing.JOptionPane.ERROR_MESSAGE;
**/
public class ShareGeneratePane extends BasicPane {
private static final Dimension DIALOG_SIZE = new Dimension(670, 740);
private static final Dimension DIALOG_SIZE = new Dimension(670, 760);
private static final Dimension DIALOG_NORMAL_SIZE = new Dimension(670, 610);
private static final Border DIALOG_BORDER = BorderFactory.createEmptyBorder(0, 6, 4, 6);

Loading…
Cancel
Save