Browse Source

修改代码检查错误

master
mengao 7 years ago
parent
commit
ff3cd152cb
  1. 5
      designer_chart/src/com/fr/design/mainframe/MiddleChartPropertyPane.java
  2. 12
      designer_chart/src/com/fr/design/mainframe/chart/ChartEditPane.java

5
designer_chart/src/com/fr/design/mainframe/MiddleChartPropertyPane.java

@ -16,6 +16,7 @@ import com.fr.design.gui.itabpane.TitleChangeListener;
import com.fr.design.mainframe.chart.ChartEditPane; import com.fr.design.mainframe.chart.ChartEditPane;
import com.fr.general.Inter; import com.fr.general.Inter;
import com.fr.stable.StableUtils; import com.fr.stable.StableUtils;
import com.fr.stable.StringUtils;
import javax.swing.*; import javax.swing.*;
import java.awt.*; import java.awt.*;
@ -64,7 +65,7 @@ public abstract class MiddleChartPropertyPane extends BaseChartPropertyPane{
chartEditPane.setContainer(container); chartEditPane.setContainer(container);
chartEditPane.addTitleChangeListener(titleListener); chartEditPane.addTitleChangeListener(titleListener);
String tabname = chartEditPane.getSelectedTabName(); String tabname = chartEditPane.getSelectedTabName();
nameLabel.setText(Inter.getLocText("Chart-Property_Table") + (tabname != null ? ('-' + chartEditPane.getSelectedTabName()) : "")); nameLabel.setText(Inter.getLocText("Chart-Property_Table") + (tabname != null ? ('-' + chartEditPane.getSelectedTabName()) : StringUtils.EMPTY));
resetChartEditPane(); resetChartEditPane();
} }
@ -155,7 +156,7 @@ public abstract class MiddleChartPropertyPane extends BaseChartPropertyPane{
* 设置是否支持单元格数据. * 设置是否支持单元格数据.
*/ */
public void setSupportCellData(boolean supportCellData) { public void setSupportCellData(boolean supportCellData) {
if(chartEditPane != null) { if (chartEditPane != null) {
chartEditPane.setSupportCellData(supportCellData); chartEditPane.setSupportCellData(supportCellData);
} }
} }

12
designer_chart/src/com/fr/design/mainframe/chart/ChartEditPane.java

@ -22,6 +22,7 @@ import com.fr.design.mainframe.chart.gui.ChartTypePane;
import com.fr.general.ComparatorUtils; import com.fr.general.ComparatorUtils;
import com.fr.general.FRLogger; import com.fr.general.FRLogger;
import com.fr.general.Inter; import com.fr.general.Inter;
import com.fr.stable.StringUtils;
import javax.swing.*; import javax.swing.*;
import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeEvent;
@ -142,7 +143,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
addTypePane(); addTypePane();
boolean isDefault = true; boolean isDefault = true;
String plotID = ""; String plotID = StringUtils.EMPTY;
if (currentChart.getPlot() != null) { if (currentChart.getPlot() != null) {
plotID = currentChart.getPlot().getPlotID(); plotID = currentChart.getPlot().getPlotID();
isDefault = ChartTypeInterfaceManager.getInstance().isUseDefaultPane(plotID); isDefault = ChartTypeInterfaceManager.getInstance().isUseDefaultPane(plotID);
@ -179,6 +180,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
} }
protected void setSelectedTab() { protected void setSelectedTab() {
//doNothing
} }
/** /**
@ -224,7 +226,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
return; return;
} }
if (checkNeedsReLayout(collection.getSelectedChart())) { if (isNeedsReLayout(collection.getSelectedChart())) {
reLayout(collection.getSelectedChart()); reLayout(collection.getSelectedChart());
} }
@ -265,7 +267,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
} }
//populate的时候看看要不要重构面板 //populate的时候看看要不要重构面板
private boolean checkNeedsReLayout(Chart chart) { private boolean isNeedsReLayout(Chart chart) {
if (chart != null) { if (chart != null) {
int lastIndex = typePane.getSelectedIndex(); int lastIndex = typePane.getSelectedIndex();
int currentIndex = getSelectedChartIndex(chart); int currentIndex = getSelectedChartIndex(chart);
@ -317,7 +319,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
} }
protected void dealWithStyleChange() { protected void dealWithStyleChange() {
//doNothing
} }
/** /**
@ -326,7 +328,7 @@ public class ChartEditPane extends BasicPane implements AttributeChange, Prepare
* @param isFromToolBar 是否来自工具栏 * @param isFromToolBar 是否来自工具栏
*/ */
public void styleChange(boolean isFromToolBar) { public void styleChange(boolean isFromToolBar) {
//doNothing
} }
/** /**

Loading…
Cancel
Save