Browse Source

hzzzz

master
hzzz 7 years ago
parent
commit
576032b7a5
  1. 4
      designer/src/com/fr/design/widget/ui/ListEditorDefinePane.java
  2. 44
      designer/src/com/fr/design/widget/ui/MultiFileEditorPane.java
  3. 5
      designer/src/com/fr/design/widget/ui/WriteUnableRepeatEditorPane.java

4
designer/src/com/fr/design/widget/ui/ListEditorDefinePane.java

@ -25,8 +25,8 @@ public class ListEditorDefinePane extends WriteUnableRepeatEditorPane<ListEditor
@Override @Override
protected JPanel setThirdContentPane() { protected JPanel setThirdContentPane() {
JPanel contenter = FRGUIPaneFactory.createBorderLayout_S_Pane(); JPanel contenter = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
JPanel centerPane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane(); JPanel centerPane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
centerPane.add(needHeadCheckBox = new UICheckBox(Inter.getLocText("List-Need_Head"))); centerPane.add(needHeadCheckBox = new UICheckBox(Inter.getLocText("List-Need_Head")));
contenter.add(centerPane); contenter.add(centerPane);
return contenter; return contenter;

44
designer/src/com/fr/design/widget/ui/MultiFileEditorPane.java

@ -12,6 +12,7 @@ import com.fr.design.gui.icombobox.DictionaryComboBox;
import com.fr.design.gui.icombobox.DictionaryConstants; import com.fr.design.gui.icombobox.DictionaryConstants;
import com.fr.design.gui.itextfield.UINumberField; import com.fr.design.gui.itextfield.UINumberField;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.FRLeftFlowLayout;
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.form.ui.MultiFileEditor; import com.fr.form.ui.MultiFileEditor;
@ -34,42 +35,35 @@ public class MultiFileEditorPane extends FieldEditorDefinePane<MultiFileEditor>
@Override @Override
protected JPanel setFirstContentPane() { protected JPanel setFirstContentPane() {
acceptType = new DictionaryComboBox(DictionaryConstants.acceptTypes, DictionaryConstants.fileTypeDisplays); JPanel contenter = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
acceptType.setPreferredSize(new Dimension(200, 18)); JPanel centerPane = FRGUIPaneFactory.createYBoxEmptyBorderPane();
// centerPane.add(singleFileCheckBox = new UICheckBox(Inter.getLocText("SINGLE_FILE_UPLOAD")));
singleFileCheckBox = new UICheckBox(Inter.getLocText("SINGLE_FILE_UPLOAD")); singleFileCheckBox = new UICheckBox(Inter.getLocText("SINGLE_FILE_UPLOAD"));
acceptType = new DictionaryComboBox(DictionaryConstants.acceptTypes, DictionaryConstants.fileTypeDisplays);
acceptType.setPreferredSize(new Dimension(100, 18));
fileSizeField = new UINumberField(); fileSizeField = new UINumberField();
fileSizeField.setPreferredSize(new Dimension(80, 18)); fileSizeField.setPreferredSize(new Dimension(80, 18));
JPanel singleFilePane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
JPanel singleFilePane = FRGUIPaneFactory.createNormalFlowInnerContainer_M_Pane();
singleFilePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
singleFilePane.add(singleFileCheckBox); singleFilePane.add(singleFileCheckBox);
centerPane.add(singleFilePane);
JPanel allowTypePane = FRGUIPaneFactory.createNormalFlowInnerContainer_M_Pane(); JPanel allowTypePane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
allowTypePane.setLayout(FRGUIPaneFactory.createLabelFlowLayout()); allowTypePane.add(new UILabel(Inter.getLocText("File-Allow_Upload_Files") + ":"));
allowTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
allowTypePane.add(new UILabel(" " + Inter.getLocText("File-Allow_Upload_Files") + ":"));
allowTypePane.add(acceptType); allowTypePane.add(acceptType);
centerPane.add(allowTypePane);
JPanel fileSizePane = FRGUIPaneFactory.createNormalFlowInnerContainer_M_Pane(); JPanel fileSizePane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
fileSizePane.add(new UILabel(" " + Inter.getLocText("File-File_Size_Limit") + ":")); fileSizePane.add(new UILabel(Inter.getLocText("File-File_Size_Limit") + ":"));
fileSizePane.add(fileSizeField); fileSizePane.add(fileSizeField);
fileSizePane.add(new UILabel(" KB")); fileSizePane.add(new UILabel(" KB"));
centerPane.add(fileSizePane);
double f = TableLayout.FILL; contenter.add(centerPane);
double p = TableLayout.PREFERRED; return contenter;
Component[][] components = new Component[][]{
new Component[]{singleFileCheckBox, null },
new Component[]{new UILabel(" " + Inter.getLocText("File-Allow_Upload_Files") + ":"), acceptType},
new Component[]{new UILabel(" " + Inter.getLocText("File-File_Size_Limit") + ":"), fileSizeField},
};
double[] rowSize = {p, p,p};
double[] columnSize = {p,f};
int[][] rowCount = {{1, 1},{1, 1},{1, 1}};
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_SMALL, 5);
return panel;
} }
@Override @Override

5
designer/src/com/fr/design/widget/ui/WriteUnableRepeatEditorPane.java

@ -20,9 +20,8 @@ public abstract class WriteUnableRepeatEditorPane<E extends WriteUnableRepeatEdi
@Override @Override
protected JPanel setFirstContentPane() { protected JPanel setFirstContentPane() {
JPanel contentPane = FRGUIPaneFactory.createY_AXISBoxInnerContainer_L_Pane(); JPanel contentPane = FRGUIPaneFactory.createYBoxEmptyBorderPane();
contentPane.setBorder(BorderFactory.createEmptyBorder(0, 2, 0, 0)); JPanel contenter=FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
JPanel contenter=FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane();
removeRepeatCheckBox = new UICheckBox(Inter.getLocText("Form-Remove_Repeat_Data"), false); removeRepeatCheckBox = new UICheckBox(Inter.getLocText("Form-Remove_Repeat_Data"), false);
contentPane.add(contenter); contentPane.add(contenter);
contenter.add(removeRepeatCheckBox); contenter.add(removeRepeatCheckBox);

Loading…
Cancel
Save