|
|
@ -23,6 +23,8 @@ import javax.swing.JSplitPane; |
|
|
|
import javax.swing.ListCellRenderer; |
|
|
|
import javax.swing.ListCellRenderer; |
|
|
|
import javax.swing.event.ListSelectionEvent; |
|
|
|
import javax.swing.event.ListSelectionEvent; |
|
|
|
import javax.swing.event.ListSelectionListener; |
|
|
|
import javax.swing.event.ListSelectionListener; |
|
|
|
|
|
|
|
import java.util.Map; |
|
|
|
|
|
|
|
import java.util.concurrent.ConcurrentHashMap; |
|
|
|
import java.awt.Color; |
|
|
|
import java.awt.Color; |
|
|
|
import java.awt.Component; |
|
|
|
import java.awt.Component; |
|
|
|
|
|
|
|
|
|
|
@ -35,6 +37,8 @@ public class ChartTypePane extends ChartCommonWizardPane implements CallbackEven |
|
|
|
private JList iconViewList = null; |
|
|
|
private JList iconViewList = null; |
|
|
|
private DefaultListModel iconListModel = null; |
|
|
|
private DefaultListModel iconListModel = null; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static Map<ChartProvider, ChartProvider> map = new ConcurrentHashMap(); |
|
|
|
|
|
|
|
|
|
|
|
public ChartTypePane() { |
|
|
|
public ChartTypePane() { |
|
|
|
this.setLayout(FRGUIPaneFactory.createBorderLayout()); |
|
|
|
this.setLayout(FRGUIPaneFactory.createBorderLayout()); |
|
|
|
DefaultListModel defaultListModel = new DefaultListModel(); |
|
|
|
DefaultListModel defaultListModel = new DefaultListModel(); |
|
|
@ -102,7 +106,11 @@ public class ChartTypePane extends ChartCommonWizardPane implements CallbackEven |
|
|
|
ChartTypePane.this.iconListModel.clear(); |
|
|
|
ChartTypePane.this.iconListModel.clear(); |
|
|
|
for (int i = 0, len = charts.length; i < len; i++) { |
|
|
|
for (int i = 0, len = charts.length; i < len; i++) { |
|
|
|
ChartProvider chart = charts[i]; |
|
|
|
ChartProvider chart = charts[i]; |
|
|
|
ChartCollection chartCollection = new ChartCollection(chart); |
|
|
|
if (map.get(chart) == null) { |
|
|
|
|
|
|
|
ChartProvider chartProvider = chart.transformProperties(); |
|
|
|
|
|
|
|
map.put(chart, chartProvider); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
ChartCollection chartCollection = new ChartCollection(map.get(chart)); |
|
|
|
ChartIcon chartIcon = new ChartIcon(chartCollection); |
|
|
|
ChartIcon chartIcon = new ChartIcon(chartCollection); |
|
|
|
chartIcon.setChartName(subName[i]); |
|
|
|
chartIcon.setChartName(subName[i]); |
|
|
|
chartIcon.registerCallBackEvent(ChartTypePane.this); |
|
|
|
chartIcon.registerCallBackEvent(ChartTypePane.this); |
|
|
|