Browse Source

组件复用设计器部分bug

master
xiaoxia 8 years ago
parent
commit
fd2f80b6c1
  1. 2
      designer/src/com/fr/design/mainframe/JWorkBook.java
  2. 4
      designer/src/com/fr/design/parameter/ParameterDefinitePane.java
  3. 8
      designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java
  4. 1
      designer_form/src/com/fr/design/form/parameter/FormParaDesigner.java
  5. 4
      designer_form/src/com/fr/design/mainframe/JForm.java

2
designer/src/com/fr/design/mainframe/JWorkBook.java

@ -732,6 +732,7 @@ public class JWorkBook extends JTemplate<WorkBook, WorkBookUndoState> {
}
} else {
DesignerContext.getDesignerFrame().resetToolkitByPlus(JWorkBook.this);
EastRegionContainerPane.getInstance().removeParameterPane();
if (delegate4ToolbarMenuAdapter() instanceof PolyDesigner) {
PolyDesigner polyDesigner = (PolyDesigner) delegate4ToolbarMenuAdapter();
if (polyDesigner.getSelectionType() == PolyDesigner.SelectionType.NONE || polyDesigner.getSelection() == null) {
@ -752,6 +753,7 @@ public class JWorkBook extends JTemplate<WorkBook, WorkBookUndoState> {
EastRegionContainerPane.getInstance().replaceUpPane(allowAuthorityUpPane());
EastRegionContainerPane.getInstance().replaceDownPane(RolesAlreadyEditedPane.getInstance());
}
centerPane.needToShowCoverAndHidPane();
}

4
designer/src/com/fr/design/parameter/ParameterDefinitePane.java

@ -20,7 +20,9 @@ import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.AuthorityToolBarPane;
import com.fr.design.mainframe.EastRegionContainerPane;
import com.fr.design.mainframe.JWorkBook;
import com.fr.design.mainframe.WidgetPropertyPane;
import com.fr.design.mainframe.toolbar.ToolBarMenuDockPlus;
import com.fr.design.menu.*;
import com.fr.design.module.DesignModuleFactory;
@ -244,7 +246,7 @@ public class ParameterDefinitePane extends JPanel implements ToolBarMenuDockPlus
isdelayItem.setSelected(reportParameterAttr.isDelayPlaying());
isshowWindowItem.setSelected(reportParameterAttr.isShowWindow());
isEditing = true;
EastRegionContainerPane.getInstance().setParameterHeight(ParameterPropertyPane.getInstance().getPreferredSize().height);
ParameterBridge bridge = paraDesignEditor.getParaComponent();
if (parameterUI != null) {
bridge.setDelayDisplayContent(reportParameterAttr.isDelayPlaying());

8
designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java

@ -29,6 +29,7 @@ public class UIResizableContainer extends JPanel {
private VerticalToolPane verticalToolPane;
private int direction;
private boolean hasParameterPane;
private static final int MAX_WIDTH = 300;
private static final int MIN_WIDTH = 165;
@ -89,7 +90,6 @@ public class UIResizableContainer extends JPanel {
add(horizontToolPane);
add(downPane);
add(verticalToolPane);
add(parameterPane);
}
public UIResizableContainer(JComponent upPane, int direction) {
@ -102,7 +102,6 @@ public class UIResizableContainer extends JPanel {
setLayout(containerLayout);
add(upPane);
add(horizontToolPane);
add(parameterPane);
}
@ -141,7 +140,7 @@ public class UIResizableContainer extends JPanel {
* @param height
*/
public void setParameterHeight(int height) {
paraHeight = height;
paraHeight = hasParameterPane? height : 0;
refreshContainer();
}
@ -274,13 +273,16 @@ public class UIResizableContainer extends JPanel {
public void addParameterPane(JComponent pane) {
add(this.parameterPane = pane);
hasParameterPane = true;
refreshContainer();
}
public void removeParameterPane() {
remove(this.parameterPane);
setParameterHeight(0);
hasParameterPane = false;
refreshContainer();
}
/**

1
designer_form/src/com/fr/design/form/parameter/FormParaDesigner.java

@ -233,6 +233,7 @@ public class FormParaDesigner extends FormDesigner implements ParameterDesignerP
}
ParameterPropertyPane.getInstance().getParameterToolbarPane().populateBean(
p.getParameterArray() == null ? new Parameter[0] : p.getParameterArray());
EastRegionContainerPane.getInstance().setParameterHeight(ParameterPropertyPane.getInstance().getPreferredSize().height);
}

4
designer_form/src/com/fr/design/mainframe/JForm.java

@ -609,17 +609,19 @@ public class JForm extends JTemplate<Form, FormUndoState> implements BaseJForm {
EastRegionContainerPane.getInstance().replaceDownPane(RolesAlreadyEditedPane.getInstance());
return;
}
if (formDesign.isReportBlockEditing()) {
if (elementCaseDesign != null) {
EastRegionContainerPane.getInstance().removeParameterPane();
EastRegionContainerPane.getInstance().replaceDownPane(elementCaseDesign.getEastDownPane());
EastRegionContainerPane.getInstance().replaceUpPane(elementCaseDesign.getEastUpPane());
return;
}
}
EastRegionContainerPane.getInstance().replaceUpPane(WidgetPropertyPane.getInstance(formDesign));
EastRegionContainerPane.getInstance().addParameterPane(ParameterPropertyPane.getInstance(formDesign));
EastRegionContainerPane.getInstance().setParameterHeight(ParameterPropertyPane.getInstance(formDesign).getPreferredSize().height);
if (EastRegionContainerPane.getInstance().getDownPane() == null) {
new Thread() {
public void run() {

Loading…
Cancel
Save