Browse Source

REPORT-4672 单元格添加控件后删除单元格所在行,右侧属性面板保持不变

master
plough 7 years ago
parent
commit
1e2fdb3455
  1. 8
      designer/src/com/fr/design/mainframe/ElementCasePaneDelegate.java
  2. 32
      designer/src/com/fr/design/mainframe/form/FormElementCasePaneDelegate.java
  3. 1
      designer/src/com/fr/poly/creator/ECBlockEditor.java

8
designer/src/com/fr/design/mainframe/ElementCasePaneDelegate.java

@ -50,18 +50,18 @@ public class ElementCasePaneDelegate extends ElementCasePane<WorkSheet> {
if (!isEditable() && !BaseUtils.isAuthorityEditing()) {
return;
}
doOnSelectionChanged(e);
refreshPropertyPanes();
}
});
this.addTargetModifiedListener(new TargetModifiedListener() {
@Override
public void targetModified(TargetModifiedEvent e) {
CellElementPropertyPane.getInstance().populate(ElementCasePaneDelegate.this);
refreshPropertyPanes();
}
});
}
private void doOnSelectionChanged(SelectionEvent e) {
private void refreshPropertyPanes() {
//在编辑权限,所以要更新权限编辑面板
if (BaseUtils.isAuthorityEditing()) {
AuthorityPropertyPane authorityPropertyPane = new AuthorityPropertyPane(ElementCasePaneDelegate.this);
@ -76,7 +76,7 @@ public class ElementCasePaneDelegate extends ElementCasePane<WorkSheet> {
QuickEditorRegion.getInstance().populate(getCurrentEditor());
JTemplate editingTemplate = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate();
if (editingTemplate != null && !editingTemplate.isUpMode()) {
Selection editingSelection = ((ElementCasePaneDelegate)e.getSource()).getSelection();
Selection editingSelection = getSelection();
// 模板初始化完成后,才能初始化超级链接面板
HyperlinkGroupPane hyperlinkGroupPane = editingTemplate.getHyperLinkPane(HyperlinkGroupPaneActionImpl.getInstance());
hyperlinkGroupPane.populate(ElementCasePaneDelegate.this);

32
designer/src/com/fr/design/mainframe/form/FormElementCasePaneDelegate.java

@ -36,32 +36,30 @@ public class FormElementCasePaneDelegate extends ElementCasePane<FormElementCase
this.addSelectionChangeListener(new SelectionListener() {
@Override
public void selectionChanged(SelectionEvent e) {
CellElementPropertyPane.getInstance().populate(FormElementCasePaneDelegate.this);
QuickEditorRegion.getInstance().populate(getCurrentEditor());
// 超级链接
HyperlinkGroupPane hyperlinkGroupPane = DesignerContext.getDesignerFrame().getSelectedJTemplate().
getHyperLinkPane(HyperlinkGroupPaneActionImpl.getInstance());
hyperlinkGroupPane.populate(FormElementCasePaneDelegate.this);
// 条件属性
ConditionAttributesGroupPane conditionAttributesGroupPane = ConditionAttributesGroupPane.getInstance();
conditionAttributesGroupPane.populate(FormElementCasePaneDelegate.this);
EastRegionContainerPane.getInstance().updateCellElementState(isSelectedOneCell());
refreshPropertyPanes();
}
});
this.addTargetModifiedListener(new TargetModifiedListener() {
@Override
public void targetModified(TargetModifiedEvent e) {
CellElementPropertyPane.getInstance().populate(FormElementCasePaneDelegate.this);
refreshPropertyPanes();
}
});
}
// private void populateHyperLinkGroupPane() {
// final TemplateElementCase report = this.getEditingElementCase();
// NameJavaScriptGroup nameHyperlinks = ReportHyperlinkGroupPane.getNameJSGroup(this, report);
// HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().getHyperLinkPane().populate(nameHyperlinks);
// }
private void refreshPropertyPanes() {
CellElementPropertyPane.getInstance().populate(FormElementCasePaneDelegate.this);
QuickEditorRegion.getInstance().populate(getCurrentEditor());
// 超级链接
HyperlinkGroupPane hyperlinkGroupPane = DesignerContext.getDesignerFrame().getSelectedJTemplate().
getHyperLinkPane(HyperlinkGroupPaneActionImpl.getInstance());
hyperlinkGroupPane.populate(FormElementCasePaneDelegate.this);
// 条件属性
ConditionAttributesGroupPane conditionAttributesGroupPane = ConditionAttributesGroupPane.getInstance();
conditionAttributesGroupPane.populate(FormElementCasePaneDelegate.this);
EastRegionContainerPane.getInstance().updateCellElementState(isSelectedOneCell());
}
@Override
protected boolean supportRepeatedHeaderFooter() {

1
designer/src/com/fr/poly/creator/ECBlockEditor.java

@ -47,6 +47,7 @@ public class ECBlockEditor extends BlockEditor<ECBlockPane, PolyECBlock> {
@Override
public void targetModified(TargetModifiedEvent e) {
designer.fireTargetModified();
resetSelectionAndChooseState();
}
});
}

Loading…
Cancel
Save