Browse Source

CHART-10358 兼容位图地图

persist/11.0
zheng 5 years ago
parent
commit
c77b13e11f
  1. 6
      designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java
  2. 5
      designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java

6
designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java

@ -374,11 +374,15 @@ public class ChartTypeInterfaceManager implements ExtraChartDesignClassManagerPr
}
result[i] = Reflect.on(chart).call("demoImagePath").get();
}
if (ArrayUtils.isNotEmpty(result)) {
return result;
}
} catch (Exception e) {
//do nothing
}
return new String[0];
return new String[]{getIconPath(chartID)};
}
public String[] getSubName(String chartID) {

5
designer-chart/src/main/java/com/fr/design/chart/ChartTypePane.java

@ -11,6 +11,7 @@ import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.log.FineLoggerFactory;
import com.fr.stable.StringUtils;
import javax.swing.BorderFactory;
import javax.swing.DefaultListCellRenderer;
@ -98,8 +99,8 @@ public class ChartTypePane extends ChartCommonWizardPane {
String[] subName = ChartTypeInterfaceManager.getInstance().getSubName(id);
ChartTypePane.this.iconListModel.clear();
for (int i = 0, len = demoImagePath.length; i < len; i++) {
String ImagePath = demoImagePath[i];
for (int i = 0, len = subName.length; i < len; i++) {
String ImagePath = demoImagePath.length > i ? demoImagePath[i] : StringUtils.EMPTY;
String chartName = subName[i];
ChartTypePane.this.iconListModel.addElement(new ChartIcon(ImagePath, chartName));
}

Loading…
Cancel
Save