yaoh.wu
7 years ago
11 changed files with 721 additions and 494 deletions
@ -0,0 +1,38 @@ |
|||||||
|
package com.fr.design.dscolumn; |
||||||
|
|
||||||
|
import com.fr.design.mainframe.cell.CellEditorPane; |
||||||
|
import com.fr.report.cell.TemplateCellElement; |
||||||
|
|
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素 数据列 基本设置内容面板 |
||||||
|
* |
||||||
|
* @author yaoh.wu |
||||||
|
* @version 2017年7月25日 |
||||||
|
* @since 9.0 |
||||||
|
*/ |
||||||
|
public class DSColumnAdvancedEditorPane extends CellEditorPane { |
||||||
|
|
||||||
|
|
||||||
|
@Override |
||||||
|
public String getIconPath() { |
||||||
|
return "Advanced"; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String title4PopupWindow() { |
||||||
|
return "Advanced"; |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
@Override |
||||||
|
public void update() { |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void populate(TemplateCellElement cellElement) { |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
} |
@ -0,0 +1,71 @@ |
|||||||
|
package com.fr.design.dscolumn; |
||||||
|
|
||||||
|
import com.fr.design.layout.TableLayout; |
||||||
|
import com.fr.design.layout.TableLayoutHelper; |
||||||
|
import com.fr.design.mainframe.cell.CellEditorPane; |
||||||
|
import com.fr.report.cell.TemplateCellElement; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
import java.awt.*; |
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素 数据列 高级设置内容面板 |
||||||
|
* |
||||||
|
* @author yaoh.wu |
||||||
|
* @version 2017年7月25日 |
||||||
|
* @since 9.0 |
||||||
|
*/ |
||||||
|
public class DSColumnBasicEditorPane extends CellEditorPane { |
||||||
|
|
||||||
|
//数据集和数据列
|
||||||
|
private SelectedDataColumnPane dataPane; |
||||||
|
//数据分组设置
|
||||||
|
private ResultSetGroupDockingPane groupPane; |
||||||
|
//当前编辑的单元格
|
||||||
|
private TemplateCellElement cellElement; |
||||||
|
|
||||||
|
public DSColumnBasicEditorPane(TemplateCellElement cellElement, SelectedDataColumnPane dataPane, ResultSetGroupDockingPane groupPane) { |
||||||
|
this.cellElement = cellElement; |
||||||
|
this.dataPane = dataPane; |
||||||
|
this.groupPane = groupPane; |
||||||
|
this.add(this.createContentPane(), BorderLayout.CENTER); |
||||||
|
} |
||||||
|
|
||||||
|
private JPanel createContentPane() { |
||||||
|
double p = TableLayout.PREFERRED; |
||||||
|
double f = TableLayout.FILL; |
||||||
|
double[] columnSize = {p, f}; |
||||||
|
double[] rowSize = {p, p}; |
||||||
|
Component[][] components = new Component[][]{ |
||||||
|
//数据集列选择
|
||||||
|
new Component[]{this.dataPane, null}, |
||||||
|
//数据分组设置
|
||||||
|
new Component[]{this.groupPane, null} |
||||||
|
}; |
||||||
|
return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getIconPath() { |
||||||
|
return "Basic"; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String title4PopupWindow() { |
||||||
|
return "Basic"; |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
@Override |
||||||
|
public void update() { |
||||||
|
dataPane.update(this.cellElement); |
||||||
|
groupPane.update(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void populate(TemplateCellElement cellElement) { |
||||||
|
this.cellElement = cellElement; |
||||||
|
dataPane.populate(null, cellElement); |
||||||
|
groupPane.populate(cellElement); |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,30 @@ |
|||||||
|
package com.fr.design.mainframe.cell; |
||||||
|
|
||||||
|
import com.fr.design.dialog.BasicPane; |
||||||
|
import com.fr.report.cell.TemplateCellElement; |
||||||
|
|
||||||
|
/** |
||||||
|
* 右侧单元格元素面板抽象类 |
||||||
|
* |
||||||
|
* @author yaoh.wu |
||||||
|
* @version 2017年7月25日 |
||||||
|
* @since 9.0 |
||||||
|
*/ |
||||||
|
public abstract class CellEditorPane extends BasicPane { |
||||||
|
|
||||||
|
public abstract String getIconPath(); |
||||||
|
|
||||||
|
public abstract String title4PopupWindow(); |
||||||
|
|
||||||
|
/** |
||||||
|
* 从面板拿数据保存 |
||||||
|
*/ |
||||||
|
public abstract void update(); |
||||||
|
|
||||||
|
/** |
||||||
|
* 更新面板数据 |
||||||
|
* |
||||||
|
* @param cellElement 单元格 |
||||||
|
*/ |
||||||
|
public abstract void populate(TemplateCellElement cellElement); |
||||||
|
} |
@ -1,57 +1,57 @@ |
|||||||
package com.fr.design.mainframe.cell; |
package com.fr.design.mainframe.cell; |
||||||
|
|
||||||
import java.awt.BorderLayout; |
|
||||||
|
|
||||||
import javax.swing.BorderFactory; |
|
||||||
import javax.swing.JPanel; |
|
||||||
|
|
||||||
import com.fr.design.gui.ilable.UILabel; |
import com.fr.design.gui.ilable.UILabel; |
||||||
import com.fr.general.Inter; |
|
||||||
import com.fr.design.selection.QuickEditor; |
import com.fr.design.selection.QuickEditor; |
||||||
|
import com.fr.general.Inter; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
import java.awt.*; |
||||||
|
|
||||||
/** |
/** |
||||||
* QuickEditorRegion |
* QuickEditorRegion |
||||||
* |
* |
||||||
* @editor zhou |
* @author zhou, yaoh.wu |
||||||
* @since 2012-3-23下午3:21:36 |
* @version 2017年7月25日 |
||||||
|
* @since 8.0 |
||||||
*/ |
*/ |
||||||
|
|
||||||
public class QuickEditorRegion extends JPanel { |
public class QuickEditorRegion extends JPanel { |
||||||
|
|
||||||
public static QuickEditorRegion getInstance() { |
|
||||||
return singleton; |
private static QuickEditorRegion singleton = new QuickEditorRegion(); |
||||||
} |
private static JPanel EMPTY; |
||||||
|
|
||||||
public static JPanel getEmptyEditor() { |
private QuickEditorRegion() { |
||||||
if(EMPTY == null) { |
this.setLayout(new BorderLayout()); |
||||||
EMPTY = new JPanel(new BorderLayout()); |
} |
||||||
UILabel content = new UILabel(Inter.getLocText(new String[]{"DataFunction-None", "HJS-Message", "Form-Widget_Property_Table"})+"!"); |
|
||||||
content.setBorder(BorderFactory.createEmptyBorder(0, 70, 0, 0)); |
public static QuickEditorRegion getInstance() { |
||||||
EMPTY.add(content, BorderLayout.CENTER); |
return singleton; |
||||||
} |
} |
||||||
return EMPTY; |
|
||||||
} |
public static JPanel getEmptyEditor() { |
||||||
|
if (EMPTY == null) { |
||||||
private static QuickEditorRegion singleton = new QuickEditorRegion(); |
EMPTY = new JPanel(new BorderLayout()); |
||||||
private static JPanel EMPTY; |
UILabel content = new UILabel(Inter.getLocText(new String[]{"DataFunction-None", "HJS-Message", "Form-Widget_Property_Table"}) + "!"); |
||||||
|
content.setBorder(BorderFactory.createEmptyBorder(0, 70, 0, 0)); |
||||||
public QuickEditorRegion() { |
EMPTY.add(content, BorderLayout.CENTER); |
||||||
this.setLayout(new BorderLayout()); |
} |
||||||
} |
return EMPTY; |
||||||
|
} |
||||||
/** |
|
||||||
* 传值 |
/** |
||||||
* |
* 更新面板显示数据 |
||||||
* @param ePane |
* |
||||||
*/ |
* @param currentEditor 当前正在编辑的单元格编辑器或者默认的单元格编辑器 |
||||||
public void populate(final QuickEditor quickEditor) { |
*/ |
||||||
this.removeAll(); |
public void populate(final QuickEditor currentEditor) { |
||||||
if(quickEditor.getComponentCount() == 0) { |
this.removeAll(); |
||||||
this.add(getEmptyEditor(), BorderLayout.CENTER); |
if (currentEditor.getComponentCount() == 0) { |
||||||
} else { |
this.add(getEmptyEditor(), BorderLayout.CENTER); |
||||||
this.add(quickEditor, BorderLayout.CENTER); |
} else { |
||||||
} |
this.add(currentEditor, BorderLayout.CENTER); |
||||||
validate(); |
} |
||||||
repaint(); |
validate(); |
||||||
} |
repaint(); |
||||||
|
} |
||||||
} |
} |
@ -1,123 +1,129 @@ |
|||||||
package com.fr.quickeditor; |
package com.fr.quickeditor; |
||||||
|
|
||||||
import com.fr.base.BaseUtils; |
import com.fr.base.BaseUtils; |
||||||
import com.fr.design.actions.utils.DeprecatedActionManager; |
import com.fr.design.actions.utils.DeprecatedActionManager; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.gui.ibutton.UIButton; |
||||||
import com.fr.design.gui.ilable.UILabel; |
import com.fr.design.gui.ilable.UILabel; |
||||||
import com.fr.design.gui.itextfield.UITextField; |
import com.fr.design.gui.itextfield.UITextField; |
||||||
import com.fr.design.layout.TableLayout; |
import com.fr.design.layout.TableLayout; |
||||||
import com.fr.design.layout.TableLayoutHelper; |
import com.fr.design.layout.TableLayoutHelper; |
||||||
import com.fr.design.mainframe.DesignerContext; |
import com.fr.design.mainframe.DesignerContext; |
||||||
import com.fr.design.mainframe.ElementCasePane; |
import com.fr.design.mainframe.ElementCasePane; |
||||||
import com.fr.design.selection.QuickEditor; |
import com.fr.design.selection.QuickEditor; |
||||||
import com.fr.design.utils.gui.GUICoreUtils; |
import com.fr.design.utils.gui.GUICoreUtils; |
||||||
import com.fr.general.Inter; |
import com.fr.general.Inter; |
||||||
import com.fr.grid.selection.CellSelection; |
import com.fr.grid.selection.CellSelection; |
||||||
import com.fr.report.cell.TemplateCellElement; |
import com.fr.report.cell.TemplateCellElement; |
||||||
import com.fr.stable.ColumnRow; |
import com.fr.stable.ColumnRow; |
||||||
|
|
||||||
import javax.swing.*; |
import javax.swing.*; |
||||||
import java.awt.*; |
import java.awt.*; |
||||||
import java.awt.event.ActionEvent; |
import java.awt.event.ActionEvent; |
||||||
import java.awt.event.ActionListener; |
import java.awt.event.ActionListener; |
||||||
import java.awt.event.MouseAdapter; |
import java.awt.event.MouseAdapter; |
||||||
import java.awt.event.MouseEvent; |
import java.awt.event.MouseEvent; |
||||||
|
|
||||||
/** |
/** |
||||||
* |
* @author zhou |
||||||
* @author zhou |
* @since 2012-7-23下午5:16:53 |
||||||
* @since 2012-7-23下午5:16:53 |
*/ |
||||||
*/ |
public abstract class CellQuickEditor extends QuickEditor<ElementCasePane> { |
||||||
public abstract class CellQuickEditor extends QuickEditor<ElementCasePane> { |
|
||||||
|
protected UITextField columnRowTextField; |
||||||
protected UITextField columnRowTextField; |
private UIButton cellElementEditButton; |
||||||
protected UIButton cellElementEditButton; |
protected TemplateCellElement cellElement; |
||||||
protected TemplateCellElement cellElement; |
|
||||||
|
public CellQuickEditor() { |
||||||
public CellQuickEditor() { |
double p = TableLayout.PREFERRED; |
||||||
double p = TableLayout.PREFERRED; |
double f = TableLayout.FILL; |
||||||
double f = TableLayout.FILL; |
double[] columnSize = {p, f}; |
||||||
double[] columnSize = { p, f }; |
double[] rowSize = {p, p, p}; |
||||||
double[] rowSize = { p,p,p}; |
Component[][] components = new Component[][]{ |
||||||
|
new Component[]{new UILabel(" " + Inter.getLocText("Cell")), columnRowTextField = initColumnRowTextField()}, |
||||||
Component[][] components = new Component[][]{ |
new Component[]{new UILabel(Inter.getLocText("HF-Insert_Content") + " "), cellElementEditButton = initCellElementEditButton()}, |
||||||
new Component[]{new UILabel(" "+Inter.getLocText("Cell")),columnRowTextField = initColumnRowTextField()}, |
new Component[]{createCenterBody(), null} |
||||||
new Component[]{new UILabel(Inter.getLocText("HF-Insert_Content")+" "),cellElementEditButton = initCellElementEditButton()}, |
}; |
||||||
new Component[]{createCenterBody(),null} |
JPanel panel = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); |
||||||
}; |
this.setLayout(new BorderLayout()); |
||||||
|
this.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); |
||||||
JPanel panel = TableLayoutHelper.createTableLayoutPane(components,rowSize,columnSize); |
this.add(panel, BorderLayout.CENTER); |
||||||
this.setLayout(new BorderLayout()); |
} |
||||||
this.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); |
|
||||||
this.add(panel,BorderLayout.CENTER); |
/** |
||||||
|
* 初始化添加按钮 |
||||||
|
* TODO 9.0 换成下拉菜单后原来的快捷键不好处理,先跳过。 |
||||||
|
* |
||||||
} |
* @return UIButton |
||||||
|
*/ |
||||||
protected UIButton initCellElementEditButton() { |
private UIButton initCellElementEditButton() { |
||||||
final UIButton cellElementEditButton = new UIButton(BaseUtils.readIcon("/com/fr/design/images/buttonicon/add.png")); |
final UIButton cellElementEditButton = new UIButton(BaseUtils.readIcon("/com/fr/design/images/buttonicon/add.png")); |
||||||
cellElementEditButton.addMouseListener(new MouseAdapter() { |
cellElementEditButton.addMouseListener(new MouseAdapter() { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public void mousePressed(MouseEvent evt) { |
public void mousePressed(MouseEvent evt) { |
||||||
GUICoreUtils.showPopMenuWithParentWidth(DeprecatedActionManager.getCellMenu(tc).createJPopupMenu(), cellElementEditButton, 0, cellElementEditButton.getY() - 6); |
GUICoreUtils.showPopMenuWithParentWidth(DeprecatedActionManager.getCellMenu(tc).createJPopupMenu(), cellElementEditButton, 0, cellElementEditButton.getY() - 6); |
||||||
} |
} |
||||||
}); |
}); |
||||||
return cellElementEditButton; |
return cellElementEditButton; |
||||||
} |
} |
||||||
|
|
||||||
protected UITextField initColumnRowTextField() { |
/** |
||||||
final UITextField columnRowTextField = new UITextField(4); |
* 初始化单元格域,存储当前选择的单元格,例A3,B4等 |
||||||
// barry:输入位置定位单元格
|
* |
||||||
columnRowTextField.addActionListener(new ActionListener() { |
* @return 单元格信息文本域 |
||||||
|
*/ |
||||||
@Override |
private UITextField initColumnRowTextField() { |
||||||
public void actionPerformed(ActionEvent e) { |
final UITextField columnRowTextField = new UITextField(4); |
||||||
ColumnRow columnRowEdit = ColumnRow.valueOf(columnRowTextField.getText()); |
|
||||||
|
// barry:输入位置定位单元格
|
||||||
// barry:检查输入是否正确
|
columnRowTextField.addActionListener(new ActionListener() { |
||||||
if (!ColumnRow.validate(columnRowEdit)) { |
@Override |
||||||
|
public void actionPerformed(ActionEvent e) { |
||||||
Object[] options = { Inter.getLocText("OK") }; |
ColumnRow columnRowEdit = ColumnRow.valueOf(columnRowTextField.getText()); |
||||||
JOptionPane.showOptionDialog(DesignerContext.getDesignerFrame(), Inter.getLocText("Please_Input_Letters+Numbers(A1,AA1,A11....)"), Inter.getLocText("Warning"), |
// barry:检查输入是否正确
|
||||||
JOptionPane.DEFAULT_OPTION, JOptionPane.WARNING_MESSAGE, null, options, options[0]); |
if (!ColumnRow.validate(columnRowEdit)) { |
||||||
|
Object[] options = {Inter.getLocText("OK")}; |
||||||
// 重新选中当前的selection,把columnRowTextField
|
JOptionPane.showOptionDialog(DesignerContext.getDesignerFrame(), Inter.getLocText("Please_Input_Letters+Numbers(A1,AA1,A11....)"), Inter.getLocText("Warning"), |
||||||
tc.setSelection(tc.getSelection()); |
JOptionPane.DEFAULT_OPTION, JOptionPane.WARNING_MESSAGE, null, options, options[0]); |
||||||
return; |
// 重新选中当前的selection,把columnRowTextField
|
||||||
} |
tc.setSelection(tc.getSelection()); |
||||||
|
return; |
||||||
JScrollBar verticalBar = tc.getVerticalScrollBar(), horizontalBar = tc.getHorizontalScrollBar(); |
} |
||||||
int m = columnRowEdit.getColumn(), n = columnRowEdit.getRow(); |
JScrollBar verticalBar = tc.getVerticalScrollBar(), horizontalBar = tc.getHorizontalScrollBar(); |
||||||
|
int m = columnRowEdit.getColumn(), n = columnRowEdit.getRow(); |
||||||
verticalBar.setMaximum(n); |
verticalBar.setMaximum(n); |
||||||
verticalBar.setValue(n < 21 ? verticalBar.getValue() : n - 20); |
verticalBar.setValue(n < 21 ? verticalBar.getValue() : n - 20); |
||||||
horizontalBar.setMaximum(m); |
horizontalBar.setMaximum(m); |
||||||
horizontalBar.setValue(m < 13 ? horizontalBar.getValue() : m - 12); |
horizontalBar.setValue(m < 13 ? horizontalBar.getValue() : m - 12); |
||||||
|
tc.setSelection(new CellSelection(m, n, 1, 1)); |
||||||
tc.setSelection(new CellSelection(m, n, 1, 1)); |
tc.requestFocus(); |
||||||
tc.requestFocus(); |
} |
||||||
} |
}); |
||||||
}); |
return columnRowTextField; |
||||||
return columnRowTextField; |
} |
||||||
} |
|
||||||
|
|
||||||
public abstract JComponent createCenterBody(); |
/** |
||||||
|
* 初始化详细信息面板 |
||||||
@Override |
* |
||||||
protected void refresh() { |
* @return JComponent 待显示的详细信息面板 |
||||||
CellSelection cs = (CellSelection)tc.getSelection(); |
*/ |
||||||
ColumnRow columnRow = ColumnRow.valueOf(cs.getColumn(), cs.getRow()); |
public abstract JComponent createCenterBody(); |
||||||
columnRowTextField.setText(columnRow.toString()); |
|
||||||
cellElement = tc.getEditingElementCase().getTemplateCellElement(cs.getColumn(), cs.getRow()); |
/** |
||||||
refreshDetails(); |
* 刷新 |
||||||
} |
*/ |
||||||
|
@Override |
||||||
protected abstract void refreshDetails(); |
protected void refresh() { |
||||||
|
CellSelection cs = (CellSelection) tc.getSelection(); |
||||||
|
ColumnRow columnRow = ColumnRow.valueOf(cs.getColumn(), cs.getRow()); |
||||||
|
columnRowTextField.setText(columnRow.toString()); |
||||||
|
cellElement = tc.getEditingElementCase().getTemplateCellElement(cs.getColumn(), cs.getRow()); |
||||||
|
refreshDetails(); |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 刷新详细信息 |
||||||
|
*/ |
||||||
|
protected abstract void refreshDetails(); |
||||||
} |
} |
@ -1,61 +1,63 @@ |
|||||||
package com.fr.quickeditor.cellquick; |
package com.fr.quickeditor.cellquick; |
||||||
|
|
||||||
import java.awt.event.ActionEvent; |
|
||||||
import java.awt.event.ActionListener; |
|
||||||
|
|
||||||
import javax.swing.BorderFactory; |
|
||||||
import javax.swing.JComponent; |
|
||||||
|
|
||||||
import com.fr.base.BaseUtils; |
import com.fr.base.BaseUtils; |
||||||
import com.fr.design.cell.editor.BiasTextPainterCellEditor.BiasTextPainterPane; |
import com.fr.design.cell.editor.BiasTextPainterCellEditor.BiasTextPainterPane; |
||||||
|
import com.fr.design.dialog.DialogActionAdapter; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.gui.ibutton.UIButton; |
||||||
import com.fr.design.mainframe.DesignerContext; |
import com.fr.design.mainframe.DesignerContext; |
||||||
import com.fr.design.dialog.DialogActionAdapter; |
|
||||||
import com.fr.general.ComparatorUtils; |
import com.fr.general.ComparatorUtils; |
||||||
import com.fr.general.Inter; |
import com.fr.general.Inter; |
||||||
import com.fr.quickeditor.CellQuickEditor; |
import com.fr.quickeditor.CellQuickEditor; |
||||||
import com.fr.report.cell.painter.BiasTextPainter; |
import com.fr.report.cell.painter.BiasTextPainter; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.awt.event.ActionListener; |
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素斜线编辑器 |
||||||
|
* TODO 9.0 大体没有改动 |
||||||
|
*/ |
||||||
public class CellBiasTextPainterEditor extends CellQuickEditor { |
public class CellBiasTextPainterEditor extends CellQuickEditor { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public JComponent createCenterBody() { |
public JComponent createCenterBody() { |
||||||
UIButton editbutton = new UIButton(Inter.getLocText("Edit"), BaseUtils.readIcon("/com/fr/design/images/m_insert/bias.png")); |
UIButton editbutton = new UIButton(Inter.getLocText("Edit"), BaseUtils.readIcon("/com/fr/design/images/m_insert/bias.png")); |
||||||
editbutton.addActionListener(new ActionListener() { |
editbutton.addActionListener(new ActionListener() { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public void actionPerformed(ActionEvent e) { |
public void actionPerformed(ActionEvent e) { |
||||||
showEditingDialog(); |
showEditingDialog(); |
||||||
} |
} |
||||||
}); |
}); |
||||||
editbutton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
editbutton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
||||||
editbutton.setMargin(null); |
editbutton.setMargin(null); |
||||||
editbutton.setOpaque(false); |
editbutton.setOpaque(false); |
||||||
return editbutton; |
return editbutton; |
||||||
} |
} |
||||||
|
|
||||||
private void showEditingDialog() { |
private void showEditingDialog() { |
||||||
final BiasTextPainter oldbiasTextPainter = (BiasTextPainter)cellElement.getValue(); |
final BiasTextPainter oldbiasTextPainter = (BiasTextPainter) cellElement.getValue(); |
||||||
final BiasTextPainterPane biasTextPainterPane = new BiasTextPainterPane(); |
final BiasTextPainterPane biasTextPainterPane = new BiasTextPainterPane(); |
||||||
biasTextPainterPane.populate(oldbiasTextPainter); |
biasTextPainterPane.populate(oldbiasTextPainter); |
||||||
biasTextPainterPane.showSmallWindow(DesignerContext.getDesignerFrame(), new DialogActionAdapter() { |
biasTextPainterPane.showSmallWindow(DesignerContext.getDesignerFrame(), new DialogActionAdapter() { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public void doOk() { |
public void doOk() { |
||||||
BiasTextPainter newbiasTextPainter = biasTextPainterPane.update(); |
BiasTextPainter newbiasTextPainter = biasTextPainterPane.update(); |
||||||
if (!ComparatorUtils.equals(oldbiasTextPainter, newbiasTextPainter)) { |
if (!ComparatorUtils.equals(oldbiasTextPainter, newbiasTextPainter)) { |
||||||
cellElement.setValue(newbiasTextPainter); |
cellElement.setValue(newbiasTextPainter); |
||||||
fireTargetModified(); |
fireTargetModified(); |
||||||
} |
} |
||||||
} |
} |
||||||
|
|
||||||
}).setVisible(true); |
}).setVisible(true); |
||||||
} |
} |
||||||
|
|
||||||
@Override |
@Override |
||||||
protected void refreshDetails() { |
protected void refreshDetails() { |
||||||
// TODO Auto-generated method stub
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
} |
} |
||||||
|
|
||||||
} |
} |
@ -1,111 +1,182 @@ |
|||||||
package com.fr.quickeditor.cellquick; |
package com.fr.quickeditor.cellquick; |
||||||
|
|
||||||
import com.fr.design.actions.columnrow.DSColumnAdvancedAction; |
import com.fr.design.dscolumn.DSColumnAdvancedEditorPane; |
||||||
import com.fr.design.actions.columnrow.DSColumnBasicAction; |
import com.fr.design.dscolumn.DSColumnBasicEditorPane; |
||||||
import com.fr.design.actions.columnrow.DSColumnConditionAction; |
import com.fr.design.dscolumn.ResultSetGroupDockingPane; |
||||||
import com.fr.design.constants.LayoutConstants; |
import com.fr.design.dscolumn.SelectedDataColumnPane; |
||||||
import com.fr.design.dscolumn.ResultSetGroupDockingPane; |
import com.fr.design.gui.ibutton.UIHeadGroup; |
||||||
import com.fr.design.dscolumn.SelectedDataColumnPane; |
import com.fr.design.mainframe.cell.CellEditorPane; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.utils.gui.GUICoreUtils; |
||||||
import com.fr.design.layout.TableLayout; |
import com.fr.quickeditor.CellQuickEditor; |
||||||
import com.fr.design.layout.TableLayoutHelper; |
|
||||||
import com.fr.quickeditor.CellQuickEditor; |
import javax.swing.*; |
||||||
|
import java.awt.*; |
||||||
import javax.swing.*; |
import java.awt.event.ItemEvent; |
||||||
import java.awt.*; |
import java.awt.event.ItemListener; |
||||||
import java.awt.event.ItemEvent; |
import java.util.ArrayList; |
||||||
import java.awt.event.ItemListener; |
|
||||||
|
/** |
||||||
public class CellDSColumnEditor extends CellQuickEditor { |
* 单元格元素 数据列编辑器 |
||||||
private JPanel dsColumnRegion; |
* |
||||||
private JPanel centerPane; |
* @author yaoh.wu |
||||||
private SelectedDataColumnPane dataPane; |
* @version 2017年7月24日 |
||||||
private ResultSetGroupDockingPane groupPane; |
* @since 9.0 |
||||||
private ItemListener groupListener = new ItemListener() { |
*/ |
||||||
|
public class CellDSColumnEditor extends CellQuickEditor { |
||||||
@Override |
|
||||||
public void itemStateChanged(ItemEvent e) { |
private JPanel dsColumnRegion; |
||||||
if (e == null) { |
private JPanel centerPane; |
||||||
//分组-高级-自定义点确定的时候传进来null的e,但是这时候应该触发保存
|
//数据集列选择组件
|
||||||
groupPane.update(); |
private SelectedDataColumnPane dataPane; |
||||||
fireTargetModified(); |
//数据分组设置组件
|
||||||
return; |
private ResultSetGroupDockingPane groupPane; |
||||||
} |
// 基本和高级设置
|
||||||
if (e.getStateChange() == ItemEvent.DESELECTED) { |
private ArrayList<CellEditorPane> paneList; |
||||||
if (!isEditing) { |
// 基本和高级设置 卡片布局
|
||||||
return; |
private CardLayout card; |
||||||
} |
// 基本和高级设置 容器面板
|
||||||
groupPane.update(); |
private JPanel center; |
||||||
fireTargetModified(); |
// 卡片布局TAB切换按钮
|
||||||
} |
private UIHeadGroup tabsHeaderIconPane; |
||||||
} |
// 分组设置监听器
|
||||||
}; |
private ItemListener groupListener = new ItemListener() { |
||||||
|
@Override |
||||||
private ItemListener dataListener = new ItemListener() { |
public void itemStateChanged(ItemEvent e) { |
||||||
|
if (e == null) { |
||||||
@Override |
//分组-高级-自定义点确定的时候传进来null的e,但是这时候应该触发保存
|
||||||
public void itemStateChanged(ItemEvent e) { |
groupPane.update(); |
||||||
if (e.getStateChange() == ItemEvent.SELECTED) { |
fireTargetModified(); |
||||||
if (!isEditing) { |
return; |
||||||
return; |
} |
||||||
} |
if (e.getStateChange() == ItemEvent.DESELECTED) { |
||||||
dataPane.update(cellElement); |
if (!isEditing) { |
||||||
fireTargetModified(); |
return; |
||||||
} |
} |
||||||
} |
groupPane.update(); |
||||||
}; |
fireTargetModified(); |
||||||
|
} |
||||||
private CellDSColumnEditor() { |
} |
||||||
super(); |
}; |
||||||
} |
//数据集列设置监听器
|
||||||
|
private ItemListener dataListener = new ItemListener() { |
||||||
@Override |
@Override |
||||||
public JComponent createCenterBody() { |
public void itemStateChanged(ItemEvent e) { |
||||||
double p = TableLayout.PREFERRED; |
if (e.getStateChange() == ItemEvent.SELECTED) { |
||||||
double f = TableLayout.FILL; |
if (!isEditing) { |
||||||
double[] columnSize = {p, f}; |
return; |
||||||
double[] rowSize = {p, p, p, p}; |
} |
||||||
Component[][] components = new Component[][]{}; |
dataPane.update(cellElement); |
||||||
dsColumnRegion = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); |
fireTargetModified(); |
||||||
centerPane = new JPanel(new BorderLayout(0, 0)); |
} |
||||||
centerPane.add(dsColumnRegion, BorderLayout.CENTER); |
} |
||||||
return centerPane; |
}; |
||||||
} |
|
||||||
|
private CellDSColumnEditor() { |
||||||
// august:这里面的东西都全部重新动态生成,不然容易出错
|
super(); |
||||||
@Override |
} |
||||||
protected void refreshDetails() { |
|
||||||
JPanel pane = new JPanel(new BorderLayout(LayoutConstants.HGAP_LARGE, 0)); |
/** |
||||||
pane.add(new UIButton(new DSColumnConditionAction(tc)), BorderLayout.WEST); |
* Test Main |
||||||
pane.add(new UIButton(new DSColumnAdvancedAction(tc)), BorderLayout.CENTER); |
* |
||||||
double p = TableLayout.PREFERRED; |
* @param args 参数 |
||||||
double f = TableLayout.FILL; |
*/ |
||||||
double[] columnSize = {p, f}; |
public static void main(String[] args) { |
||||||
double[] rowSize = {p, p, p, p}; |
JFrame jf = new JFrame("test"); |
||||||
Component[][] components = new Component[][]{ |
jf.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); |
||||||
new Component[]{new UIButton(new DSColumnBasicAction(tc)), null}, |
JPanel content = (JPanel) jf.getContentPane(); |
||||||
new Component[]{pane, null}, |
content.setLayout(new BorderLayout()); |
||||||
new Component[]{dataPane = new SelectedDataColumnPane(false), null}, |
content.add(new CellDSColumnEditor(), BorderLayout.CENTER); |
||||||
new Component[]{groupPane = new ResultSetGroupDockingPane(tc), null} |
GUICoreUtils.centerWindow(jf); |
||||||
}; |
jf.setSize(220, 400); |
||||||
centerPane.removeAll(); |
jf.setVisible(true); |
||||||
dsColumnRegion = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); |
} |
||||||
centerPane.add(dsColumnRegion, BorderLayout.CENTER); |
|
||||||
dataPane.addListener(dataListener); |
/** |
||||||
groupPane.addListener(groupListener); |
* @return JComponent 详细信息面板 |
||||||
dataPane.populate(null, cellElement); |
*/ |
||||||
groupPane.populate(cellElement); |
@Override |
||||||
this.validate(); |
public JComponent createCenterBody() { |
||||||
} |
this.initPaneList(); |
||||||
|
this.initSwitchTab(); |
||||||
|
dsColumnRegion = new JPanel(new BorderLayout()); |
||||||
/** |
dsColumnRegion.add(tabsHeaderIconPane, BorderLayout.NORTH); |
||||||
* for 关闭时候释放 |
dsColumnRegion.add(center, BorderLayout.CENTER); |
||||||
*/ |
centerPane = new JPanel(new BorderLayout()); |
||||||
public void release () { |
centerPane.add(dsColumnRegion, BorderLayout.CENTER); |
||||||
super.release(); |
return centerPane; |
||||||
dsColumnRegion = null; |
} |
||||||
centerPane = null; |
|
||||||
} |
/** |
||||||
|
* TODO 内容全部重新动态生成,不然容易出错 |
||||||
|
* 刷新详细信息面板 |
||||||
|
*/ |
||||||
|
@Override |
||||||
|
protected void refreshDetails() { |
||||||
|
|
||||||
|
for (CellEditorPane cellEditorPane : paneList) { |
||||||
|
cellEditorPane.populate(cellElement); |
||||||
|
} |
||||||
|
this.validate(); |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
/** |
||||||
|
* 关闭时候释放 |
||||||
|
*/ |
||||||
|
public void release() { |
||||||
|
super.release(); |
||||||
|
dsColumnRegion = null; |
||||||
|
centerPane = null; |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 初始化数据列基本和高级设置面板 |
||||||
|
*/ |
||||||
|
private void initPaneList() { |
||||||
|
paneList = new ArrayList<>(); |
||||||
|
|
||||||
|
paneList.add(this.initBasicPane()); |
||||||
|
paneList.add(this.initAdvancedPane()); |
||||||
|
|
||||||
|
/* |
||||||
|
todo 预留插件的接口 |
||||||
|
doSomething() |
||||||
|
*/ |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 初始化基本和高级设置切换tab |
||||||
|
*/ |
||||||
|
private void initSwitchTab() { |
||||||
|
String[] iconArray = new String[paneList.size()]; |
||||||
|
card = new CardLayout(); |
||||||
|
center = new JPanel(card); |
||||||
|
for (int i = 0; i < paneList.size(); i++) { |
||||||
|
CellEditorPane pane = paneList.get(i); |
||||||
|
iconArray[i] = pane.getIconPath(); |
||||||
|
center.add(pane, pane.title4PopupWindow()); |
||||||
|
} |
||||||
|
tabsHeaderIconPane = new UIHeadGroup(iconArray) { |
||||||
|
@Override |
||||||
|
public void tabChanged(int index) { |
||||||
|
card.show(center, paneList.get(index).title4PopupWindow()); |
||||||
|
paneList.get(index).populate(cellElement); |
||||||
|
} |
||||||
|
}; |
||||||
|
tabsHeaderIconPane.setNeedLeftRightOutLine(false); |
||||||
|
} |
||||||
|
|
||||||
|
private DSColumnBasicEditorPane initBasicPane() { |
||||||
|
|
||||||
|
this.dataPane = new SelectedDataColumnPane(false); |
||||||
|
this.groupPane = new ResultSetGroupDockingPane(tc); |
||||||
|
dataPane.addListener(dataListener); |
||||||
|
groupPane.addListener(groupListener); |
||||||
|
return new DSColumnBasicEditorPane(cellElement, dataPane, groupPane); |
||||||
|
} |
||||||
|
|
||||||
|
private DSColumnAdvancedEditorPane initAdvancedPane() { |
||||||
|
return new DSColumnAdvancedEditorPane(); |
||||||
|
} |
||||||
|
|
||||||
} |
} |
@ -1,75 +1,77 @@ |
|||||||
package com.fr.quickeditor.cellquick; |
package com.fr.quickeditor.cellquick; |
||||||
|
|
||||||
import java.awt.event.ActionEvent; |
|
||||||
import java.awt.event.ActionListener; |
|
||||||
|
|
||||||
import javax.swing.BorderFactory; |
|
||||||
import javax.swing.JComponent; |
|
||||||
|
|
||||||
import com.fr.base.BaseUtils; |
import com.fr.base.BaseUtils; |
||||||
import com.fr.base.Style; |
import com.fr.base.Style; |
||||||
|
import com.fr.design.dialog.DialogActionAdapter; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.gui.ibutton.UIButton; |
||||||
import com.fr.design.mainframe.DesignerContext; |
import com.fr.design.mainframe.DesignerContext; |
||||||
import com.fr.design.report.SelectImagePane; |
import com.fr.design.report.SelectImagePane; |
||||||
import com.fr.design.dialog.DialogActionAdapter; |
|
||||||
import com.fr.general.ComparatorUtils; |
import com.fr.general.ComparatorUtils; |
||||||
import com.fr.general.Inter; |
import com.fr.general.Inter; |
||||||
import com.fr.quickeditor.CellQuickEditor; |
import com.fr.quickeditor.CellQuickEditor; |
||||||
import com.fr.report.cell.cellattr.CellImage; |
import com.fr.report.cell.cellattr.CellImage; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.awt.event.ActionListener; |
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素图片编辑器 |
||||||
|
* TODO 9.0大体上没有改动 |
||||||
|
*/ |
||||||
public class CellImageQuickEditor extends CellQuickEditor { |
public class CellImageQuickEditor extends CellQuickEditor { |
||||||
private static CellImageQuickEditor THIS; |
private static CellImageQuickEditor THIS; |
||||||
|
|
||||||
public static final CellImageQuickEditor getInstance() { |
public static final CellImageQuickEditor getInstance() { |
||||||
if(THIS == null) { |
if (THIS == null) { |
||||||
THIS = new CellImageQuickEditor(); |
THIS = new CellImageQuickEditor(); |
||||||
} |
} |
||||||
return THIS; |
return THIS; |
||||||
} |
} |
||||||
|
|
||||||
private CellImageQuickEditor() { |
private CellImageQuickEditor() { |
||||||
super(); |
super(); |
||||||
} |
} |
||||||
|
|
||||||
@Override |
@Override |
||||||
public JComponent createCenterBody() { |
public JComponent createCenterBody() { |
||||||
UIButton editbutton = new UIButton(Inter.getLocText("Edit"), BaseUtils.readIcon("/com/fr/design/images/m_insert/image.png")); |
UIButton editbutton = new UIButton(Inter.getLocText("Edit"), BaseUtils.readIcon("/com/fr/design/images/m_insert/image.png")); |
||||||
editbutton.addActionListener(new ActionListener() { |
editbutton.addActionListener(new ActionListener() { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public void actionPerformed(ActionEvent e) { |
public void actionPerformed(ActionEvent e) { |
||||||
showEditingDialog(); |
showEditingDialog(); |
||||||
} |
} |
||||||
}); |
}); |
||||||
editbutton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
editbutton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
||||||
editbutton.setMargin(null); |
editbutton.setMargin(null); |
||||||
editbutton.setOpaque(false); |
editbutton.setOpaque(false); |
||||||
return editbutton; |
return editbutton; |
||||||
} |
} |
||||||
|
|
||||||
private void showEditingDialog() { |
private void showEditingDialog() { |
||||||
final SelectImagePane imageEditorPane = new SelectImagePane(); |
final SelectImagePane imageEditorPane = new SelectImagePane(); |
||||||
imageEditorPane.populate(cellElement); |
imageEditorPane.populate(cellElement); |
||||||
final Object oldValue = cellElement.getValue(); |
final Object oldValue = cellElement.getValue(); |
||||||
final Style oldStyle = cellElement.getStyle(); |
final Style oldStyle = cellElement.getStyle(); |
||||||
imageEditorPane.showWindow(DesignerContext.getDesignerFrame(), new DialogActionAdapter() { |
imageEditorPane.showWindow(DesignerContext.getDesignerFrame(), new DialogActionAdapter() { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public void doOk() { |
public void doOk() { |
||||||
CellImage cellImage = imageEditorPane.update(); |
CellImage cellImage = imageEditorPane.update(); |
||||||
if (!ComparatorUtils.equals(cellImage.getImage(), oldValue) || !ComparatorUtils.equals(cellImage.getStyle(), oldStyle)) { |
if (!ComparatorUtils.equals(cellImage.getImage(), oldValue) || !ComparatorUtils.equals(cellImage.getStyle(), oldStyle)) { |
||||||
cellElement.setValue(cellImage.getImage()); |
cellElement.setValue(cellImage.getImage()); |
||||||
cellElement.setStyle(cellImage.getStyle()); |
cellElement.setStyle(cellImage.getStyle()); |
||||||
fireTargetModified(); |
fireTargetModified(); |
||||||
} |
} |
||||||
} |
} |
||||||
|
|
||||||
}).setVisible(true); |
}).setVisible(true); |
||||||
} |
} |
||||||
|
|
||||||
@Override |
@Override |
||||||
protected void refreshDetails() { |
protected void refreshDetails() { |
||||||
|
|
||||||
} |
} |
||||||
|
|
||||||
} |
} |
@ -1,50 +1,50 @@ |
|||||||
package com.fr.quickeditor.cellquick; |
package com.fr.quickeditor.cellquick; |
||||||
|
|
||||||
import javax.swing.BorderFactory; |
|
||||||
import javax.swing.JComponent; |
|
||||||
|
|
||||||
import com.fr.design.actions.insert.cell.RichTextCellAction; |
import com.fr.design.actions.insert.cell.RichTextCellAction; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.gui.ibutton.UIButton; |
||||||
import com.fr.general.Inter; |
import com.fr.general.Inter; |
||||||
import com.fr.quickeditor.CellQuickEditor; |
import com.fr.quickeditor.CellQuickEditor; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素富文本编辑器 |
||||||
|
* TODO 9.0 大体上没有改动 |
||||||
|
*/ |
||||||
public class CellRichTextEditor extends CellQuickEditor { |
public class CellRichTextEditor extends CellQuickEditor { |
||||||
private UIButton subReportButton; |
private UIButton subReportButton; |
||||||
private static CellRichTextEditor THIS; |
private static CellRichTextEditor THIS; |
||||||
|
|
||||||
public static final CellRichTextEditor getInstance() { |
public static final CellRichTextEditor getInstance() { |
||||||
if(THIS == null) { |
if (THIS == null) { |
||||||
THIS = new CellRichTextEditor(); |
THIS = new CellRichTextEditor(); |
||||||
} |
} |
||||||
return THIS; |
return THIS; |
||||||
} |
} |
||||||
|
|
||||||
private CellRichTextEditor() { |
private CellRichTextEditor() { |
||||||
super(); |
super(); |
||||||
} |
} |
||||||
|
|
||||||
/** |
/** |
||||||
* 创建界面上中间的部分 |
* 创建界面上中间的部分 |
||||||
* |
* |
||||||
* @return 界面元素 |
* @return 界面元素 |
||||||
* |
* @date 2014-12-7-下午9:41:52 |
||||||
* |
*/ |
||||||
* @date 2014-12-7-下午9:41:52 |
public JComponent createCenterBody() { |
||||||
* |
subReportButton = new UIButton(); |
||||||
*/ |
subReportButton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
||||||
public JComponent createCenterBody() { |
subReportButton.setMargin(null); |
||||||
subReportButton = new UIButton(); |
subReportButton.setOpaque(false); |
||||||
subReportButton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
return subReportButton; |
||||||
subReportButton.setMargin(null); |
} |
||||||
subReportButton.setOpaque(false); |
|
||||||
return subReportButton; |
@Override |
||||||
} |
protected void refreshDetails() { |
||||||
|
RichTextCellAction subReportCellAction = new RichTextCellAction(tc); |
||||||
@Override |
subReportCellAction.setName(Inter.getLocText("FR-Designer_RichTextEditor")); |
||||||
protected void refreshDetails() { |
subReportButton.setAction(subReportCellAction); |
||||||
RichTextCellAction subReportCellAction = new RichTextCellAction(tc); |
} |
||||||
subReportCellAction.setName(Inter.getLocText("FR-Designer_RichTextEditor")); |
|
||||||
subReportButton.setAction(subReportCellAction); |
|
||||||
} |
|
||||||
|
|
||||||
} |
} |
@ -1,42 +1,45 @@ |
|||||||
package com.fr.quickeditor.cellquick; |
package com.fr.quickeditor.cellquick; |
||||||
|
|
||||||
import javax.swing.BorderFactory; |
|
||||||
import javax.swing.JComponent; |
|
||||||
|
|
||||||
import com.fr.design.actions.insert.cell.SubReportCellAction; |
import com.fr.design.actions.insert.cell.SubReportCellAction; |
||||||
import com.fr.design.gui.ibutton.UIButton; |
import com.fr.design.gui.ibutton.UIButton; |
||||||
import com.fr.general.Inter; |
import com.fr.general.Inter; |
||||||
import com.fr.quickeditor.CellQuickEditor; |
import com.fr.quickeditor.CellQuickEditor; |
||||||
|
|
||||||
|
import javax.swing.*; |
||||||
|
|
||||||
|
/** |
||||||
|
* 单元格元素子报表编辑器 |
||||||
|
* TODO 9.0大体上没有改动 |
||||||
|
*/ |
||||||
public class CellSubReportEditor extends CellQuickEditor { |
public class CellSubReportEditor extends CellQuickEditor { |
||||||
private UIButton subReportButton; |
private UIButton subReportButton; |
||||||
private static CellSubReportEditor THIS; |
private static CellSubReportEditor THIS; |
||||||
|
|
||||||
public static final CellSubReportEditor getInstance() { |
public static final CellSubReportEditor getInstance() { |
||||||
if(THIS == null) { |
if (THIS == null) { |
||||||
THIS = new CellSubReportEditor(); |
THIS = new CellSubReportEditor(); |
||||||
} |
} |
||||||
return THIS; |
return THIS; |
||||||
} |
} |
||||||
|
|
||||||
private CellSubReportEditor() { |
private CellSubReportEditor() { |
||||||
super(); |
super(); |
||||||
} |
} |
||||||
|
|
||||||
@Override |
@Override |
||||||
public JComponent createCenterBody() { |
public JComponent createCenterBody() { |
||||||
subReportButton = new UIButton(); |
subReportButton = new UIButton(); |
||||||
subReportButton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
subReportButton.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); |
||||||
subReportButton.setMargin(null); |
subReportButton.setMargin(null); |
||||||
subReportButton.setOpaque(false); |
subReportButton.setOpaque(false); |
||||||
return subReportButton; |
return subReportButton; |
||||||
} |
} |
||||||
|
|
||||||
@Override |
@Override |
||||||
protected void refreshDetails() { |
protected void refreshDetails() { |
||||||
SubReportCellAction subReportCellAction = new SubReportCellAction(tc); |
SubReportCellAction subReportCellAction = new SubReportCellAction(tc); |
||||||
subReportCellAction.setName(Inter.getLocText(new String[]{"Edit", "Sub_Report"})); |
subReportCellAction.setName(Inter.getLocText(new String[]{"Edit", "Sub_Report"})); |
||||||
subReportButton.setAction(subReportCellAction); |
subReportButton.setAction(subReportCellAction); |
||||||
} |
} |
||||||
|
|
||||||
} |
} |
Loading…
Reference in new issue