|
|
|
@ -1,6 +1,5 @@
|
|
|
|
|
package com.fr.design.report.fit.menupane; |
|
|
|
|
|
|
|
|
|
import com.fr.design.file.HistoryTemplateListCache; |
|
|
|
|
import com.fr.design.i18n.Toolkit; |
|
|
|
|
import com.fr.design.mainframe.JTemplate; |
|
|
|
|
import com.fr.design.report.fit.BaseFitAttrPane; |
|
|
|
@ -15,7 +14,10 @@ import java.awt.event.ItemListener;
|
|
|
|
|
|
|
|
|
|
public class TemplateFitAttrPane extends BaseFitAttrPane { |
|
|
|
|
|
|
|
|
|
public TemplateFitAttrPane() { |
|
|
|
|
private JTemplate jwb; |
|
|
|
|
|
|
|
|
|
public TemplateFitAttrPane(JTemplate jwb) { |
|
|
|
|
this.jwb = jwb; |
|
|
|
|
initComponents(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -23,7 +25,7 @@ public class TemplateFitAttrPane extends BaseFitAttrPane {
|
|
|
|
|
protected void initComponents() { |
|
|
|
|
super.initComponents(); |
|
|
|
|
for (FitAttrModel fitAttrModel : fitAttrModelList) { |
|
|
|
|
if (fitAttrModel.isAvailable(HistoryTemplateListCache.getInstance().getCurrentEditingTemplate())) { |
|
|
|
|
if (fitAttrModel.isAvailable(jwb)) { |
|
|
|
|
populateModel(fitAttrModel); |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
@ -71,7 +73,6 @@ public class TemplateFitAttrPane extends BaseFitAttrPane {
|
|
|
|
|
public void itemStateChanged(ItemEvent e) { |
|
|
|
|
if (e.getStateChange() == ItemEvent.SELECTED) { |
|
|
|
|
if(isTemplateSingleSet()){ |
|
|
|
|
JTemplate jwb = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); |
|
|
|
|
if (jwb != null) { |
|
|
|
|
FitProvider wbTpl = (FitProvider) jwb.getTarget(); |
|
|
|
|
ReportFitAttr fitAttr = wbTpl.getReportFitAttr(); |
|
|
|
|