Browse Source

Merge pull request #1060 in BA/design from ~KERRY/design:9.0 to 9.0

* commit 'accb33d4d1594eb742bacea7b062a6ee9d5fd1dc':
  只监听失去焦点
  删除无用import
  修改border
  将UIHeadGroup换成用UIButtonGroup
  REPORT-3293 调整border 控件对齐
master
superman 7 years ago
parent
commit
6b58777137
  1. 85
      designer/src/com/fr/design/widget/CellWidgetCardPane.java
  2. 2
      designer/src/com/fr/design/widget/ui/BasicWidgetPropertySettingPane.java
  3. 3
      designer/src/com/fr/design/widget/ui/ButtonGroupDictPane.java
  4. 14
      designer/src/com/fr/design/widget/ui/CheckBoxDictPane.java
  5. 16
      designer/src/com/fr/design/widget/ui/CheckBoxGroupDefinePane.java
  6. 1
      designer/src/com/fr/design/widget/ui/ComboBoxDefinePane.java
  7. 3
      designer/src/com/fr/design/widget/ui/ComboCheckBoxDefinePane.java
  8. 4
      designer/src/com/fr/design/widget/ui/CustomWritableRepeatEditorPane.java
  9. 8
      designer/src/com/fr/design/widget/ui/DirectWriteEditorDefinePane.java
  10. 12
      designer/src/com/fr/design/widget/ui/FieldEditorDefinePane.java
  11. 4
      designer/src/com/fr/design/widget/ui/ListEditorDefinePane.java
  12. 1
      designer/src/com/fr/design/widget/ui/MultiFileEditorPane.java
  13. 9
      designer/src/com/fr/design/widget/ui/NumberEditorDefinePane.java
  14. 8
      designer/src/com/fr/design/widget/ui/TextFieldEditorDefinePane.java
  15. 3
      designer/src/com/fr/design/widget/ui/TreeEditorDefinePane.java
  16. 2
      designer/src/com/fr/design/widget/ui/WaterMarkDictPane.java
  17. 2
      designer/src/com/fr/design/widget/ui/WriteUnableRepeatEditorPane.java
  18. 2
      designer/src/com/fr/design/widget/ui/btn/DefineDeleteColumnRowPane.java
  19. 6
      designer/src/com/fr/design/widget/ui/btn/FreeButtonDetailPane.java
  20. 1
      designer_base/src/com/fr/design/gui/itextfield/UITextField.java
  21. 8
      designer_base/src/com/fr/design/gui/itree/refreshabletree/TreeRootPane.java
  22. 2
      designer_base/src/com/fr/design/widget/btn/ButtonWithHotkeysDetailPane.java
  23. 31
      designer_base/src/com/fr/design/widget/component/BackgroundCompPane.java
  24. 2
      designer_base/src/com/fr/design/widget/component/ButtonBackgroundPane.java
  25. 2
      designer_form/src/com/fr/design/mainframe/widget/ui/FormWidgetCardPane.java
  26. 25
      designer_form/src/com/fr/design/widget/ui/designer/CheckBoxGroupDefinePane.java
  27. 23
      designer_form/src/com/fr/design/widget/ui/designer/ComboCheckBoxDefinePane.java
  28. 9
      designer_form/src/com/fr/design/widget/ui/designer/DateEditorDefinePane.java
  29. 38
      designer_form/src/com/fr/design/widget/ui/designer/component/FormWidgetValuePane.java
  30. 2
      designer_form/src/com/fr/design/widget/ui/designer/component/TabFitLayoutBackgroundPane.java

85
designer/src/com/fr/design/widget/CellWidgetCardPane.java

@ -3,14 +3,11 @@ package com.fr.design.widget;
import com.fr.design.data.DataCreatorUI; import com.fr.design.data.DataCreatorUI;
import com.fr.design.dialog.BasicPane; import com.fr.design.dialog.BasicPane;
import com.fr.design.foldablepane.UIExpandablePane; import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.gui.frpane.TreeSettingPane;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIHeadGroup;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.ElementCasePane; import com.fr.design.mainframe.ElementCasePane;
import com.fr.design.present.dict.DictionaryPane;
import com.fr.design.widget.ui.BasicWidgetPropertySettingPane; import com.fr.design.widget.ui.BasicWidgetPropertySettingPane;
import com.fr.form.event.Listener; import com.fr.form.event.Listener;
import com.fr.form.ui.NoneWidget;
import com.fr.form.ui.Widget; import com.fr.form.ui.Widget;
import com.fr.general.Inter; import com.fr.general.Inter;
@ -36,14 +33,6 @@ public class CellWidgetCardPane extends BasicPane {
private JPanel attriCardPane; private JPanel attriCardPane;
private CardLayout attriCardLayout; private CardLayout attriCardLayout;
//数字字典属性容器
private JPanel dictTabPane;
private JPanel dictCardPane;
private CardLayout dictCardLayout;
//构建树属性容器
private JPanel treeTabPane;
//事件属性容器 //事件属性容器
private JPanel eventTabPane; private JPanel eventTabPane;
private WidgetEventPane eventPane; private WidgetEventPane eventPane;
@ -52,11 +41,6 @@ public class CellWidgetCardPane extends BasicPane {
public CellWidgetCardPane(ElementCasePane pane) { public CellWidgetCardPane(ElementCasePane pane) {
this.pane = pane; this.pane = pane;
// this.initComponents(pane);
}
public BasicWidgetPropertySettingPane initBasicWidgetPropertyPane() {
return new BasicWidgetPropertySettingPane();
} }
@ -88,16 +72,6 @@ public class CellWidgetCardPane extends BasicPane {
tabsHeaderIconPane.setNeedLeftRightOutLine(false); tabsHeaderIconPane.setNeedLeftRightOutLine(false);
this.add(tabsHeaderIconPane, BorderLayout.NORTH); this.add(tabsHeaderIconPane, BorderLayout.NORTH);
//数据字典
dictTabPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
dictCardPane = FRGUIPaneFactory.createCardLayout_S_Pane();
dictTabPane.add(dictCardPane, BorderLayout.CENTER);
dictCardLayout = new CardLayout();
dictCardPane.setLayout(dictCardLayout);
//构建树
treeTabPane = FRGUIPaneFactory.createBorderLayout_L_Pane();
widgetPropertyPane = new BasicWidgetPropertySettingPane(); widgetPropertyPane = new BasicWidgetPropertySettingPane();
UIExpandablePane uiExpandablePane = new UIExpandablePane(Inter.getLocText("FR-Designer_Basic"), 280, 24, widgetPropertyPane); UIExpandablePane uiExpandablePane = new UIExpandablePane(Inter.getLocText("FR-Designer_Basic"), 280, 24, widgetPropertyPane);
@ -124,31 +98,12 @@ public class CellWidgetCardPane extends BasicPane {
public void populate(Widget cellWidget) { public void populate(Widget cellWidget) {
initComponents(pane); initComponents(pane);
// super.populate(cellWidget);
currentEditorDefinePane = null; currentEditorDefinePane = null;
if (cellWidget instanceof NoneWidget) {
// this.tabbedPane.setEnabled(false);
} else {
// this.tabbedPane.setEnabled(true);
}
WidgetDefinePaneFactory.RN rn = WidgetDefinePaneFactory.createWidgetDefinePane(cellWidget, new Operator() { WidgetDefinePaneFactory.RN rn = WidgetDefinePaneFactory.createWidgetDefinePane(cellWidget, new Operator() {
@Override @Override
public void did(DataCreatorUI ui, String cardName) { public void did(DataCreatorUI ui, String cardName) {
if (ui == null) { //todo
removeDictAttriPane();
removeTreeAttriPane();
}
if (ui instanceof DictionaryPane) {
removeDictAttriPane();
removeTreeAttriPane();
showDictPane(ui, cardName);
} else if (ui instanceof TreeSettingPane) {
removeDictAttriPane();
removeTreeAttriPane();
showTreePane(ui);
}
} }
}); });
DataModify<? extends Widget> definePane = rn.getDefinePane(); DataModify<? extends Widget> definePane = rn.getDefinePane();
@ -160,19 +115,6 @@ public class CellWidgetCardPane extends BasicPane {
tabsHeaderIconPane.setSelectedIndex(0); tabsHeaderIconPane.setSelectedIndex(0);
} }
private void showDictPane(DataCreatorUI ui, String cardName) {
dictCardPane.removeAll();
dictCardPane.add(ui.toSwingComponent(), cardName);
dictCardLayout.show(dictCardPane, cardName);
addDictAttriPane();
}
private void showTreePane(DataCreatorUI ui) {
treeTabPane.removeAll();
treeTabPane.add(ui.toSwingComponent());
addTreeAttriPane();
}
public Widget update() { public Widget update() {
if (currentEditorDefinePane == null) { if (currentEditorDefinePane == null) {
return null; return null;
@ -182,7 +124,6 @@ public class CellWidgetCardPane extends BasicPane {
return null; return null;
} }
widgetPropertyPane.update(widget); widgetPropertyPane.update(widget);
// super.update(widget);
Listener[] listener = eventPane == null ? new Listener[0] : eventPane.updateListeners(); Listener[] listener = eventPane == null ? new Listener[0] : eventPane.updateListeners();
widget.clearListeners(); widget.clearListeners();
@ -203,28 +144,4 @@ public class CellWidgetCardPane extends BasicPane {
eventPane.checkValid(); eventPane.checkValid();
} }
private void addDictAttriPane() {
center.add(this.dictTabPane, Inter.getLocText("FR-Designer_DS_Dictionary"));
reInitHeaderPane(this.dictTabPane);
}
private void addTreeAttriPane() {
center.add(this.dictTabPane, Inter.getLocText("FR-Designer_Create_Tree"));
reInitHeaderPane(this.treeTabPane);
}
private void removeDictAttriPane() {
center.remove(this.dictTabPane);
}
private void removeTreeAttriPane() {
center.remove(this.treeTabPane);
}
private void reInitHeaderPane(JPanel jPanel) {
paneList.add(jPanel);
// tabsHeaderIconPane = new
}
} }

2
designer/src/com/fr/design/widget/ui/BasicWidgetPropertySettingPane.java

@ -25,6 +25,8 @@ public class BasicWidgetPropertySettingPane extends BasicPane {
this.setLayout(new BorderLayout()); this.setLayout(new BorderLayout());
enableCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Visible"), true); enableCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Visible"), true);
visibleCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Widget-Visible"), true); visibleCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Widget-Visible"), true);
enableCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
visibleCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
widgetNameComboBox = new ParameterTreeComboBox(); widgetNameComboBox = new ParameterTreeComboBox();
widgetNameComboBox.refreshTree(); widgetNameComboBox.refreshTree();
double f = TableLayout.FILL; double f = TableLayout.FILL;

3
designer/src/com/fr/design/widget/ui/ButtonGroupDictPane.java

@ -39,6 +39,7 @@ public class ButtonGroupDictPane extends JPanel {
dictPane = new AccessibleDictionaryEditor(); dictPane = new AccessibleDictionaryEditor();
this.setLayout(FRGUIPaneFactory.createBorderLayout()); this.setLayout(FRGUIPaneFactory.createBorderLayout());
adaptiveCheckbox = new UICheckBox(Inter.getLocText("Adaptive"), true); adaptiveCheckbox = new UICheckBox(Inter.getLocText("Adaptive"), true);
adaptiveCheckbox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
adaptiveCheckbox.addActionListener(new ActionListener() { adaptiveCheckbox.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) { public void actionPerformed(ActionEvent e) {
columnSpinner.setVisible(!adaptiveCheckbox.isSelected()); columnSpinner.setVisible(!adaptiveCheckbox.isSelected());
@ -57,7 +58,7 @@ public class ButtonGroupDictPane extends JPanel {
{adaptiveCheckbox, columnLabel, columnSpinner} {adaptiveCheckbox, columnLabel, columnSpinner}
}; };
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(n_components, rowSize, columnSize, 16, 8); JPanel panel = TableLayoutHelper.createGapTableLayoutPane(n_components, rowSize, columnSize, 16, 8);
panel.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5)); panel.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0));
this.add(panel); this.add(panel);

14
designer/src/com/fr/design/widget/ui/CheckBoxDictPane.java

@ -1,14 +1,11 @@
package com.fr.design.widget.ui; package com.fr.design.widget.ui;
import java.awt.*; import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import javax.swing.JPanel; import javax.swing.JPanel;
import com.fr.design.gui.icombobox.UIComboBox;
import com.fr.design.gui.icombobox.DictionaryComboBox; 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.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
@ -20,7 +17,7 @@ import com.fr.general.Inter;
public class CheckBoxDictPane extends JPanel { public class CheckBoxDictPane extends JPanel {
private DictionaryComboBox delimiterComboBox; private DictionaryComboBox delimiterComboBox;
private UIHeadGroup returnTypeComboBox; private UIButtonGroup returnTypeComboBox;
private DictionaryComboBox startComboBox; private DictionaryComboBox startComboBox;
private DictionaryComboBox endComboBox; private DictionaryComboBox endComboBox;
@ -46,12 +43,7 @@ public class CheckBoxDictPane extends JPanel {
endPane.add(new UILabel(Inter.getLocText("ComboCheckBox-End_Symbol") + ":"), BorderLayout.WEST); endPane.add(new UILabel(Inter.getLocText("ComboCheckBox-End_Symbol") + ":"), BorderLayout.WEST);
endPane.add(endComboBox = new DictionaryComboBox(DictionaryConstants.symbols, DictionaryConstants.symbolDisplays), BorderLayout.CENTER); endPane.add(endComboBox = new DictionaryComboBox(DictionaryConstants.symbols, DictionaryConstants.symbolDisplays), BorderLayout.CENTER);
endComboBox.setEditable(true); endComboBox.setEditable(true);
returnTypeComboBox = new UIHeadGroup(new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")}){ returnTypeComboBox = new UIButtonGroup(new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")});
protected void tabChanged(int newSelectedIndex) {
// checkVisible(newSelectedIndex);
//todo
}
};
returnTypePane.add(returnTypeComboBox, BorderLayout.CENTER); returnTypePane.add(returnTypeComboBox, BorderLayout.CENTER);
JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{new UILabel(Inter.getLocText("Widget-Date_Selector_Return_Type") + ":"), returnTypePane}}, TableLayoutHelper.FILL_LASTCOLUMN, 18, 7); JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{new UILabel(Inter.getLocText("Widget-Date_Selector_Return_Type") + ":"), returnTypePane}}, TableLayoutHelper.FILL_LASTCOLUMN, 18, 7);
this.add(jPanel); this.add(jPanel);

16
designer/src/com/fr/design/widget/ui/CheckBoxGroupDefinePane.java

@ -4,23 +4,15 @@ import java.awt.*;
import javax.swing.BorderFactory; import javax.swing.BorderFactory;
import javax.swing.JPanel; import javax.swing.JPanel;
import com.fr.data.Dictionary;
import com.fr.design.data.DataCreatorUI; import com.fr.design.data.DataCreatorUI;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
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.widget.accessibles.AccessibleDictionaryEditor;
import com.fr.design.present.dict.DictionaryPane;
import com.fr.design.widget.ui.designer.component.FormWidgetValuePane;
import com.fr.form.ui.CheckBoxGroup; import com.fr.form.ui.CheckBoxGroup;
import com.fr.general.Inter; import com.fr.general.Inter;
public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup> { public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup> {
private AccessibleDictionaryEditor dictPane;
CheckBoxDictPane checkBoxDictPane; CheckBoxDictPane checkBoxDictPane;
private UICheckBox checkbox; private UICheckBox checkbox;
@ -44,8 +36,8 @@ public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup
@Override @Override
protected JPanel setFirstContentPane() { protected JPanel setFirstContentPane() {
JPanel advancePane = FRGUIPaneFactory.createBorderLayout_S_Pane(); JPanel advancePane = FRGUIPaneFactory.createBorderLayout_S_Pane();
dictPane = new AccessibleDictionaryEditor();
checkbox = new UICheckBox(Inter.getLocText(new String[]{"Provide", "Choose_All"})); checkbox = new UICheckBox(Inter.getLocText(new String[]{"Provide", "Choose_All"}));
checkbox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
buttonGroupDictPane = new ButtonGroupDictPane(); buttonGroupDictPane = new ButtonGroupDictPane();
checkBoxDictPane = new CheckBoxDictPane(); checkBoxDictPane = new CheckBoxDictPane();
double f = TableLayout.FILL; double f = TableLayout.FILL;
@ -53,7 +45,6 @@ public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup
Component[][] components = new Component[][]{ Component[][] components = new Component[][]{
new Component[]{buttonGroupDictPane, null }, new Component[]{buttonGroupDictPane, null },
new Component[]{checkbox, null }, new Component[]{checkbox, null },
new Component[]{new UILabel(Inter.getLocText("FR-Designer_DS-Dictionary")), dictPane },
new Component[]{checkBoxDictPane, null }, new Component[]{checkBoxDictPane, null },
}; };
@ -61,7 +52,7 @@ public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup
double[] columnSize = {p, f}; double[] columnSize = {p, f};
int[][] rowCount = {{1, 1},{1, 1},{1,1},{1,1}}; int[][] rowCount = {{1, 1},{1, 1},{1,1},{1,1}};
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 10, 7); JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 10, 7);
panel.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0)); // panel.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0));
advancePane.add(panel); advancePane.add(panel);
return advancePane; return advancePane;
@ -69,7 +60,6 @@ public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup
@Override @Override
protected void populateSubFieldEditorBean(CheckBoxGroup ob) { protected void populateSubFieldEditorBean(CheckBoxGroup ob) {
this.dictPane.setValue(ob.getDictionary());
checkBoxDictPane.populate(ob); checkBoxDictPane.populate(ob);
checkbox.setSelected(ob.isChooseAll()); checkbox.setSelected(ob.isChooseAll());
this.buttonGroupDictPane.populate(ob); this.buttonGroupDictPane.populate(ob);
@ -78,8 +68,6 @@ public class CheckBoxGroupDefinePane extends FieldEditorDefinePane<CheckBoxGroup
@Override @Override
protected CheckBoxGroup updateSubFieldEditorBean() { protected CheckBoxGroup updateSubFieldEditorBean() {
CheckBoxGroup ob = new CheckBoxGroup(); CheckBoxGroup ob = new CheckBoxGroup();
ob.setDictionary((Dictionary) this.dictPane.getValue());
checkBoxDictPane.update(ob); checkBoxDictPane.update(ob);
ob.setChooseAll(checkbox.isSelected()); ob.setChooseAll(checkbox.isSelected());
this.buttonGroupDictPane.update(ob); this.buttonGroupDictPane.update(ob);

1
designer/src/com/fr/design/widget/ui/ComboBoxDefinePane.java

@ -7,7 +7,6 @@ import com.fr.design.data.DataCreatorUI;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.TableLayoutHelper; import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.widget.accessibles.AccessibleDictionaryEditor; import com.fr.design.mainframe.widget.accessibles.AccessibleDictionaryEditor;
import com.fr.design.present.dict.DictionaryPane;
import com.fr.form.ui.ComboBox; import com.fr.form.ui.ComboBox;
import com.fr.general.Inter; import com.fr.general.Inter;

3
designer/src/com/fr/design/widget/ui/ComboCheckBoxDefinePane.java

@ -8,10 +8,8 @@ import com.fr.design.layout.FRGUIPaneFactory;
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.widget.accessibles.AccessibleDictionaryEditor; import com.fr.design.mainframe.widget.accessibles.AccessibleDictionaryEditor;
import com.fr.design.present.dict.DictionaryPane;
import com.fr.form.ui.ComboCheckBox; import com.fr.form.ui.ComboCheckBox;
import com.fr.general.Inter; import com.fr.general.Inter;
import com.fr.third.fr.pdf.layout.border.Border;
import javax.swing.*; import javax.swing.*;
import java.awt.*; import java.awt.*;
@ -30,6 +28,7 @@ public class ComboCheckBoxDefinePane extends CustomWritableRepeatEditorPane<Comb
dictPane = new AccessibleDictionaryEditor(); dictPane = new AccessibleDictionaryEditor();
checkBoxDictPane = new CheckBoxDictPane(); checkBoxDictPane = new CheckBoxDictPane();
supportTagCheckBox = new UICheckBox(Inter.getLocText("Form-SupportTag"), true); supportTagCheckBox = new UICheckBox(Inter.getLocText("Form-SupportTag"), true);
supportTagCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
JPanel advancePane = FRGUIPaneFactory.createBorderLayout_S_Pane(); JPanel advancePane = FRGUIPaneFactory.createBorderLayout_S_Pane();
double f = TableLayout.FILL; double f = TableLayout.FILL;
double p = TableLayout.PREFERRED; double p = TableLayout.PREFERRED;

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

@ -32,6 +32,7 @@ public abstract class CustomWritableRepeatEditorPane<T extends CustomWriteAbleRe
this.customDataCheckBox = new UICheckBox(Inter.getLocText("Form-Allow_CustomData"), false); this.customDataCheckBox = new UICheckBox(Inter.getLocText("Form-Allow_CustomData"), false);
this.customDataCheckBox.setPreferredSize( this.customDataCheckBox.setPreferredSize(
new Dimension(CUSTOM_DATA_CHECK_BOX_WIDTH, CUSTOM_DATA_CHECK_BOX_HEIGHT)); new Dimension(CUSTOM_DATA_CHECK_BOX_WIDTH, CUSTOM_DATA_CHECK_BOX_HEIGHT));
this.customDataCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
JPanel otherContentPane = this.setForthContentPane(); JPanel otherContentPane = this.setForthContentPane();
return otherContentPane; return otherContentPane;
} }
@ -39,7 +40,8 @@ public abstract class CustomWritableRepeatEditorPane<T extends CustomWriteAbleRe
public JPanel setValidatePane(){ public JPanel setValidatePane(){
JPanel otherContentPane = super.setValidatePane(); JPanel otherContentPane = super.setValidatePane();
otherContentPane.add(GUICoreUtils.createFlowPane(new JComponent[]{customDataCheckBox}, FlowLayout.LEFT, 5)); JPanel jPanel = GUICoreUtils.createFlowPane(new JComponent[]{customDataCheckBox}, FlowLayout.LEFT, 0);
otherContentPane.add(jPanel, BorderLayout.CENTER);
return otherContentPane; return otherContentPane;
} }

8
designer/src/com/fr/design/widget/ui/DirectWriteEditorDefinePane.java

@ -1,10 +1,7 @@
package com.fr.design.widget.ui; package com.fr.design.widget.ui;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.utils.gui.GUICoreUtils; import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.form.ui.DirectWriteEditor; import com.fr.form.ui.DirectWriteEditor;
import com.fr.general.Inter; import com.fr.general.Inter;
@ -42,8 +39,9 @@ public abstract class DirectWriteEditorDefinePane<T extends DirectWriteEditor> e
public JPanel setValidatePane(){ public JPanel setValidatePane(){
JPanel otherContentPane = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); JPanel otherContentPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
otherContentPane.add(GUICoreUtils.createFlowPane(new JComponent[]{directWriteCheckBox}, FlowLayout.LEFT, 5)); JPanel jPanel = GUICoreUtils.createFlowPane(new JComponent[]{directWriteCheckBox}, FlowLayout.LEFT, 0);
otherContentPane.add(jPanel, BorderLayout.NORTH);
return otherContentPane; return otherContentPane;
} }

12
designer/src/com/fr/design/widget/ui/FieldEditorDefinePane.java

@ -68,7 +68,6 @@ public abstract class FieldEditorDefinePane<T extends FieldEditor> extends Abstr
@Override @Override
public void populateBean(T ob) { public void populateBean(T ob) {
this.allowBlankCheckBox.setSelected(ob.isAllowBlank()); this.allowBlankCheckBox.setSelected(ob.isAllowBlank());
// errorMsgTextField.setEnabled(!allowBlankCheckBox.isSelected());
this.errorMsgTextField.setText(ob.getErrorMessage()); this.errorMsgTextField.setText(ob.getErrorMessage());
populateSubFieldEditorBean(ob); populateSubFieldEditorBean(ob);
@ -101,7 +100,7 @@ public abstract class FieldEditorDefinePane<T extends FieldEditor> extends Abstr
final UILabel uiLabel = new UILabel(Inter.getLocText(new String[]{"FR-Designer_Error", "FR-Designer_Tooltips"})); final UILabel uiLabel = new UILabel(Inter.getLocText(new String[]{"FR-Designer_Error", "FR-Designer_Tooltips"}));
errorMsgTextField = new UITextField(10); errorMsgTextField = new UITextField(10);
allowBlankCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Null")); allowBlankCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Null"));
allowBlankCheckBox.setBorder(BorderFactory.createEmptyBorder(5, 5, 0, 5)); allowBlankCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
allowBlankCheckBox.setPreferredSize(new Dimension(ALLOW_BLANK_CHECK_BOX_WIDTH, ALLOW_BLANK_CHECK_BOX_HEIGHT)); allowBlankCheckBox.setPreferredSize(new Dimension(ALLOW_BLANK_CHECK_BOX_WIDTH, ALLOW_BLANK_CHECK_BOX_HEIGHT));
allowBlankCheckBox.addItemListener(new ItemListener() { allowBlankCheckBox.addItemListener(new ItemListener() {
@ -141,15 +140,6 @@ public abstract class FieldEditorDefinePane<T extends FieldEditor> extends Abstr
UIExpandablePane uiExpandablePane = new UIExpandablePane(Inter.getLocText("FR-Designer_Validate"), 280, 24, validatePane); UIExpandablePane uiExpandablePane = new UIExpandablePane(Inter.getLocText("FR-Designer_Validate"), 280, 24, validatePane);
this.add(uiExpandablePane, BorderLayout.CENTER); this.add(uiExpandablePane, BorderLayout.CENTER);
// JPanel firstPane = GUICoreUtils.createFlowPane(new JComponent[]{allowBlankCheckBox}, FlowLayout.LEFT, 5);
// validatePane.add(firstPane);
// JPanel secondPane = new JPanel(FRGUIPaneFactory.createLabelFlowLayout());
// secondPane.add(new UILabel("错误提示" + ":"));
// secondPane.add(errorMsgTextField);
// JPanel secondPane = GUICoreUtils.createFlowPane(new JComponent[]{new UILabel(Inter.getLocText(new String[]{"Error", "Tooltips"}) + ":"), errorMsgTextField}, FlowLayout.LEFT, 24);
// secondPane.setPreferredSize(new Dimension(400, 23));
// validatePane.add(secondPane);
} }
public JPanel setValidatePane() { public JPanel setValidatePane() {

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

@ -1,6 +1,6 @@
package com.fr.design.widget.ui; package com.fr.design.widget.ui;
import javax.swing.JPanel; import javax.swing.*;
import com.fr.data.Dictionary; import com.fr.data.Dictionary;
import com.fr.design.data.DataCreatorUI; import com.fr.design.data.DataCreatorUI;
@ -8,7 +8,6 @@ import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.widget.accessibles.AccessibleDictionaryEditor; import com.fr.design.mainframe.widget.accessibles.AccessibleDictionaryEditor;
import com.fr.design.present.dict.DictionaryPane;
import com.fr.form.ui.ListEditor; import com.fr.form.ui.ListEditor;
import com.fr.general.Inter; import com.fr.general.Inter;
@ -38,6 +37,7 @@ public class ListEditorDefinePane extends WriteUnableRepeatEditorPane<ListEditor
JPanel contenter = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0(); JPanel contenter = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0();
JPanel centerPane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane_First0(); 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")));
needHeadCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
contenter.add(centerPane); contenter.add(centerPane);
return contenter; return contenter;
} }

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

@ -33,6 +33,7 @@ public class MultiFileEditorPane extends FieldEditorDefinePane<MultiFileEditor>
JPanel contenter = new JPanel(new BorderLayout()); JPanel contenter = new JPanel(new BorderLayout());
singleFileCheckBox = new UICheckBox(Inter.getLocText("SINGLE_FILE_UPLOAD")); singleFileCheckBox = new UICheckBox(Inter.getLocText("SINGLE_FILE_UPLOAD"));
singleFileCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
acceptType = new DictionaryComboBox(DictionaryConstants.acceptTypes, DictionaryConstants.fileTypeDisplays); acceptType = new DictionaryComboBox(DictionaryConstants.acceptTypes, DictionaryConstants.fileTypeDisplays);
// acceptType.setPreferredSize(new Dimension(100, 20)); // acceptType.setPreferredSize(new Dimension(100, 20));
fileSizeField = new UISpinner(0, Integer.MAX_VALUE, 1, -1); fileSizeField = new UISpinner(0, Integer.MAX_VALUE, 1, -1);

9
designer/src/com/fr/design/widget/ui/NumberEditorDefinePane.java

@ -3,15 +3,13 @@ package com.fr.design.widget.ui;
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.ItemEvent;
import java.awt.event.ItemListener;
import javax.swing.BorderFactory; import javax.swing.BorderFactory;
import javax.swing.JComponent; import javax.swing.JComponent;
import javax.swing.JFormattedTextField; import javax.swing.JFormattedTextField;
import com.fr.design.constants.LayoutConstants; import com.fr.design.constants.LayoutConstants;
import com.fr.design.constants.UIConstants;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import javax.swing.JPanel; import javax.swing.JPanel;
@ -172,6 +170,7 @@ public class NumberEditorDefinePane extends FieldEditorDefinePane<NumberEditor>
public JPanel setValidatePane() { public JPanel setValidatePane() {
this.allowDecimalsCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Decimals")); this.allowDecimalsCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Decimals"));
allowDecimalsCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.decimalLength = new UIBasicSpinner(new SpinnerNumberModel(16, 0, Integer.MAX_VALUE, 1)); this.decimalLength = new UIBasicSpinner(new SpinnerNumberModel(16, 0, Integer.MAX_VALUE, 1));
this.decimalLength.setPreferredSize(new Dimension(155, 20)); this.decimalLength.setPreferredSize(new Dimension(155, 20));
@ -179,8 +178,10 @@ public class NumberEditorDefinePane extends FieldEditorDefinePane<NumberEditor>
this.allowNegativeCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Negative")); this.allowNegativeCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Allow_Negative"));
this.allowNegativeCheckBox.addActionListener(actionListener2); this.allowNegativeCheckBox.addActionListener(actionListener2);
allowNegativeCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.setMaxValueCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Max_Value"), false); this.setMaxValueCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Max_Value"), false);
setMaxValueCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.maxValueSpinner = new UIBasicSpinner(maxValueModel = new SpinnerNumberModel(0D, -Double.MAX_VALUE, Double.MAX_VALUE, 1D)); this.maxValueSpinner = new UIBasicSpinner(maxValueModel = new SpinnerNumberModel(0D, -Double.MAX_VALUE, Double.MAX_VALUE, 1D));
maxValueSpinner.setPreferredSize(new Dimension(155, 20)); maxValueSpinner.setPreferredSize(new Dimension(155, 20));
@ -190,6 +191,8 @@ public class NumberEditorDefinePane extends FieldEditorDefinePane<NumberEditor>
this.maxValueSpinner.addChangeListener(changeListener1); this.maxValueSpinner.addChangeListener(changeListener1);
this.setMinValueCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Min_Value"), false); this.setMinValueCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Min_Value"), false);
setMinValueCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.minValueSpinner = new UIBasicSpinner(minValueModel = new SpinnerNumberModel(0D, -Double.MAX_VALUE, Double.MAX_VALUE, 1D)); this.minValueSpinner = new UIBasicSpinner(minValueModel = new SpinnerNumberModel(0D, -Double.MAX_VALUE, Double.MAX_VALUE, 1D));
minValueSpinner.setPreferredSize(new Dimension(155, 20)); minValueSpinner.setPreferredSize(new Dimension(155, 20));
setNotAllowsInvalid(this.minValueSpinner); setNotAllowsInvalid(this.minValueSpinner);

8
designer/src/com/fr/design/widget/ui/TextFieldEditorDefinePane.java

@ -1,12 +1,14 @@
package com.fr.design.widget.ui; package com.fr.design.widget.ui;
import com.fr.design.gui.frpane.RegPane; import com.fr.design.gui.frpane.RegPane;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.form.ui.TextEditor; import com.fr.form.ui.TextEditor;
import com.fr.form.ui.reg.RegExp; import com.fr.form.ui.reg.RegExp;
import com.fr.general.Inter; import com.fr.general.Inter;
import com.fr.stable.StringUtils; import com.fr.stable.StringUtils;
import javax.swing.*; import javax.swing.*;
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.KeyAdapter; import java.awt.event.KeyAdapter;
@ -56,8 +58,10 @@ public class TextFieldEditorDefinePane extends FieldEditorDefinePane<TextEditor>
} }
}); });
JPanel jPanel = FRGUIPaneFactory.createBorderLayout_S_Pane();
return waterMarkDictPane; jPanel.add(waterMarkDictPane, BorderLayout.CENTER);
waterMarkDictPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 10, 0));
return jPanel;
} }
public JPanel setValidatePane(){ public JPanel setValidatePane(){

3
designer/src/com/fr/design/widget/ui/TreeEditorDefinePane.java

@ -5,9 +5,6 @@ import com.fr.design.gui.frpane.TreeSettingPane;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.itree.refreshabletree.TreeRootPane; import com.fr.design.gui.itree.refreshabletree.TreeRootPane;
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.TableLayoutHelper;
import com.fr.form.ui.TreeEditor; import com.fr.form.ui.TreeEditor;
import com.fr.general.Inter; import com.fr.general.Inter;

2
designer/src/com/fr/design/widget/ui/WaterMarkDictPane.java

@ -3,13 +3,11 @@ package com.fr.design.widget.ui;
import java.awt.*; import java.awt.*;
import java.awt.event.KeyListener; import java.awt.event.KeyListener;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import javax.swing.*; import javax.swing.*;
import com.fr.design.gui.itextfield.UITextField; import com.fr.design.gui.itextfield.UITextField;
import com.fr.design.layout.FRGUIPaneFactory;
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.WaterMark; import com.fr.form.ui.WaterMark;

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

@ -6,7 +6,6 @@ import javax.swing.BorderFactory;
import javax.swing.JPanel; import javax.swing.JPanel;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.TableLayout; import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper; import com.fr.design.layout.TableLayoutHelper;
@ -25,6 +24,7 @@ public abstract class WriteUnableRepeatEditorPane<E extends WriteUnableRepeatEdi
protected JPanel setFirstContentPane() { protected JPanel setFirstContentPane() {
JPanel contentPane = FRGUIPaneFactory.createYBoxEmptyBorderPane(); JPanel contentPane = FRGUIPaneFactory.createYBoxEmptyBorderPane();
removeRepeatCheckBox = new UICheckBox(Inter.getLocText("Form-Remove_Repeat_Data"), false); removeRepeatCheckBox = new UICheckBox(Inter.getLocText("Form-Remove_Repeat_Data"), false);
removeRepeatCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
Component[] dicPane = createDicPane(); Component[] dicPane = createDicPane();
double f = TableLayout.FILL; double f = TableLayout.FILL;

2
designer/src/com/fr/design/widget/ui/btn/DefineDeleteColumnRowPane.java

@ -38,7 +38,7 @@ public class DefineDeleteColumnRowPane extends BasicPane {
{ new UILabel(Inter.getLocText(new String[]{"Specify", "Cell"}) + ":"), crEditor }, { new UILabel(Inter.getLocText(new String[]{"Specify", "Cell"}) + ":"), crEditor },
{new UILabel(Inter.getLocText("Append_Delete_Row_Message")),null}}; {new UILabel(Inter.getLocText("Append_Delete_Row_Message")),null}};
JPanel contentPane = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); JPanel contentPane = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
contentPane.setBorder(BorderFactory.createEmptyBorder(10, 0, 0, 0));
setLayout(FRGUIPaneFactory.createBorderLayout()); setLayout(FRGUIPaneFactory.createBorderLayout());
add(contentPane); add(contentPane);

6
designer/src/com/fr/design/widget/ui/btn/FreeButtonDetailPane.java

@ -9,13 +9,17 @@ import com.fr.form.ui.FreeButton;
import com.fr.design.widget.btn.ButtonWithHotkeysDetailPane; import com.fr.design.widget.btn.ButtonWithHotkeysDetailPane;
import com.fr.general.Inter; import com.fr.general.Inter;
import javax.swing.*;
public class FreeButtonDetailPane extends ButtonWithHotkeysDetailPane<FreeButton> { public class FreeButtonDetailPane extends ButtonWithHotkeysDetailPane<FreeButton> {
private ButtonBackgroundPane backgroundCompPane; private ButtonBackgroundPane backgroundCompPane;
@Override @Override
protected Component createCenterPane() { protected Component createCenterPane() {
backgroundCompPane = new ButtonBackgroundPane(); backgroundCompPane = new ButtonBackgroundPane();
return TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background") + ":"), backgroundCompPane}}, TableLayoutHelper.FILL_LASTCOLUMN, 18, 7); JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background") + ":"), backgroundCompPane}}, TableLayoutHelper.FILL_LASTCOLUMN, 18, 7);
jPanel.setBorder(BorderFactory.createEmptyBorder(10, 0, 0, 0));
return jPanel;
} }
@Override @Override

1
designer_base/src/com/fr/design/gui/itextfield/UITextField.java

@ -64,7 +64,6 @@ public class UITextField extends JTextField implements UIObserver, GlobalNameObs
addFocusListener(new FocusListener() { addFocusListener(new FocusListener() {
@Override @Override
public void focusGained(FocusEvent e) { public void focusGained(FocusEvent e) {
attributeChange();
} }
@Override @Override

8
designer_base/src/com/fr/design/gui/itree/refreshabletree/TreeRootPane.java

@ -32,23 +32,31 @@ public class TreeRootPane extends BasicPane {
JPanel checkTypePane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0(); JPanel checkTypePane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0();
checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
checkTypeCheckBox = new UICheckBox(Inter.getLocText("Tree-Mutiple_Selection_Or_Not")); checkTypeCheckBox = new UICheckBox(Inter.getLocText("Tree-Mutiple_Selection_Or_Not"));
checkTypeCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
checkTypePane.add(checkTypeCheckBox); checkTypePane.add(checkTypeCheckBox);
this.add(checkTypePane); this.add(checkTypePane);
JPanel loadTypePane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0(); JPanel loadTypePane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0();
checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
loadTypeCheckBox = new UICheckBox(Inter.getLocText("Widget-Load_By_Async")); loadTypeCheckBox = new UICheckBox(Inter.getLocText("Widget-Load_By_Async"));
loadTypeCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
loadTypePane.add(loadTypeCheckBox); loadTypePane.add(loadTypeCheckBox);
this.add(loadTypePane); this.add(loadTypePane);
JPanel leafSelectPane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0(); JPanel leafSelectPane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0();
checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
leafSelectPane.add(layerTypeCheckBox = new UICheckBox(Inter.getLocText("Tree-Select_Leaf_Only"))); leafSelectPane.add(layerTypeCheckBox = new UICheckBox(Inter.getLocText("Tree-Select_Leaf_Only")));
layerTypeCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.add(leafSelectPane); this.add(leafSelectPane);
JPanel returnFullPathPane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0(); JPanel returnFullPathPane = FRGUIPaneFactory.createBoxFlowInnerContainer_S_Pane_First0();
checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); checkTypePane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
returnFullPathPane.add(returnFullPathCheckBox = new UICheckBox(Inter.getLocText("Tree-Return_Full_Path"))); returnFullPathPane.add(returnFullPathCheckBox = new UICheckBox(Inter.getLocText("Tree-Return_Full_Path")));
returnFullPathCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
this.add(returnFullPathPane); this.add(returnFullPathPane);
} }

2
designer_base/src/com/fr/design/widget/btn/ButtonWithHotkeysDetailPane.java

@ -49,7 +49,7 @@ public abstract class ButtonWithHotkeysDetailPane<T extends Button> extends Butt
}; };
hotkeysTextField.setToolTipText(StableUtils.join(ButtonConstants.HOTKEYS, ",")); hotkeysTextField.setToolTipText(StableUtils.join(ButtonConstants.HOTKEYS, ","));
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(n_components, rowSize, columnSize, 16, 8); JPanel panel = TableLayoutHelper.createGapTableLayoutPane(n_components, rowSize, columnSize, 16, 8);
advancePane.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5)); panel.setBorder(BorderFactory.createEmptyBorder(10, 0, 0, 0));
advancePane.add(panel, BorderLayout.NORTH); advancePane.add(panel, BorderLayout.NORTH);
Component comp = createCenterPane(); Component comp = createCenterPane();
if(comp != null ) { if(comp != null ) {

31
designer_base/src/com/fr/design/widget/component/BackgroundCompPane.java

@ -1,14 +1,13 @@
package com.fr.design.widget.component; package com.fr.design.widget.component;
import com.fr.design.dialog.BasicPane; import com.fr.design.dialog.BasicPane;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
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.widget.accessibles.AccessibleBackgroundEditor; import com.fr.design.mainframe.widget.accessibles.AccessibleBackgroundEditor;
import com.fr.form.ui.Widget; import com.fr.form.ui.Widget;
import com.fr.general.Background;
import com.fr.general.Inter; import com.fr.general.Inter;
import javax.swing.*; import javax.swing.*;
@ -18,11 +17,11 @@ import java.awt.*;
* Created by ibm on 2017/8/6. * Created by ibm on 2017/8/6.
*/ */
public abstract class BackgroundCompPane<T extends Widget> extends BasicPane { public abstract class BackgroundCompPane<T extends Widget> extends BasicPane {
protected UIHeadGroup backgroundHead; protected UIButtonGroup backgroundHead;
protected AccessibleBackgroundEditor initalBackgroundEditor; protected AccessibleBackgroundEditor initalBackgroundEditor;
protected AccessibleBackgroundEditor overBackgroundEditor; protected AccessibleBackgroundEditor overBackgroundEditor;
protected AccessibleBackgroundEditor clickBackgroundEditor; protected AccessibleBackgroundEditor clickBackgroundEditor;
private JPanel panel;
public BackgroundCompPane() { public BackgroundCompPane() {
initComponent(); initComponent();
@ -45,27 +44,23 @@ public abstract class BackgroundCompPane<T extends Widget> extends BasicPane {
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background-Over")), overBackgroundEditor}, new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background-Over")), overBackgroundEditor},
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background-Click")), clickBackgroundEditor}, new Component[]{new UILabel(Inter.getLocText("FR-Designer_Background-Click")), clickBackgroundEditor},
}; };
final JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 7, 7); panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 7, 7);
panel.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5)); panel.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
backgroundHead = new UIHeadGroup(titles){ backgroundHead = new UIButtonGroup(titles);
@Override
public void tabChanged(int index) {
//todo
if (index == 1) {
panel.setVisible(true);
}else{
panel.setVisible(false);
}
}
};
this.add(backgroundHead, BorderLayout.NORTH); this.add(backgroundHead, BorderLayout.NORTH);
this.add(panel, BorderLayout.CENTER); this.add(panel, BorderLayout.CENTER);
} }
public abstract void update(T e); public void update(T e){
}
public void populate(T e){
}
public abstract void populate(T e); public void switchCard(){
panel.setVisible(backgroundHead.getSelectedIndex() == 1);
}
} }

2
designer_base/src/com/fr/design/widget/component/ButtonBackgroundPane.java

@ -25,6 +25,7 @@ public class ButtonBackgroundPane extends BackgroundCompPane<FreeButton> {
freeButton.setOverBackground((Background) overBackgroundEditor.getValue()); freeButton.setOverBackground((Background) overBackgroundEditor.getValue());
freeButton.setClickBackground((Background)clickBackgroundEditor.getValue()); freeButton.setClickBackground((Background)clickBackgroundEditor.getValue());
} }
switchCard();
} }
public void populate(FreeButton freeButton){ public void populate(FreeButton freeButton){
@ -39,6 +40,7 @@ public class ButtonBackgroundPane extends BackgroundCompPane<FreeButton> {
overBackgroundEditor.setValue(freeButton.getOverBackground()); overBackgroundEditor.setValue(freeButton.getOverBackground());
clickBackgroundEditor.setValue(freeButton.getClickBackground()); clickBackgroundEditor.setValue(freeButton.getClickBackground());
} }
switchCard();
} }
protected String title4PopupWindow() { protected String title4PopupWindow() {

2
designer_form/src/com/fr/design/mainframe/widget/ui/FormWidgetCardPane.java

@ -6,6 +6,7 @@ import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.gui.frpane.AbstractAttrNoScrollPane; import com.fr.design.gui.frpane.AbstractAttrNoScrollPane;
import com.fr.design.gui.frpane.AttributeChangeListener; import com.fr.design.gui.frpane.AttributeChangeListener;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.DesignerContext;
import com.fr.design.mainframe.FormDesigner; import com.fr.design.mainframe.FormDesigner;
import com.fr.design.widget.DataModify; import com.fr.design.widget.DataModify;
import com.fr.design.widget.Operator; import com.fr.design.widget.Operator;
@ -214,6 +215,7 @@ public class FormWidgetCardPane extends AbstractAttrNoScrollPane {
public void fireValueChanged() { public void fireValueChanged() {
designer.repaint(); designer.repaint();
DesignerContext.getDesignerFrame().getSelectedJTemplate().fireTargetModified();
} }
public String getIconPath() { public String getIconPath() {

25
designer_form/src/com/fr/design/widget/ui/designer/CheckBoxGroupDefinePane.java

@ -2,6 +2,7 @@ package com.fr.design.widget.ui.designer;
import com.fr.design.data.DataCreatorUI; import com.fr.design.data.DataCreatorUI;
import com.fr.design.designer.creator.XCreator; import com.fr.design.designer.creator.XCreator;
import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIHeadGroup;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
@ -17,7 +18,7 @@ import java.awt.*;
public class CheckBoxGroupDefinePane extends ButtonGroupDefinePane<CheckBoxGroup> { public class CheckBoxGroupDefinePane extends ButtonGroupDefinePane<CheckBoxGroup> {
private DictionaryPane dictPane; private DictionaryPane dictPane;
private UIHeadGroup returnType; private UIButtonGroup returnType;
private UICheckBox checkbox; private UICheckBox checkbox;
public CheckBoxGroupDefinePane(XCreator xCreator) { public CheckBoxGroupDefinePane(XCreator xCreator) {
@ -42,18 +43,7 @@ public class CheckBoxGroupDefinePane extends ButtonGroupDefinePane<CheckBoxGroup
checkbox = new UICheckBox(Inter.getLocText(new String[]{"Provide", "Choose_All"})); checkbox = new UICheckBox(Inter.getLocText(new String[]{"Provide", "Choose_All"}));
checkbox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); checkbox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
final String[] tabTitles = new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")}; final String[] tabTitles = new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")};
returnType = new UIHeadGroup(tabTitles) { returnType = new UIButtonGroup(tabTitles);
@Override
public void tabChanged(int index) {
CheckBoxGroup combo = (CheckBoxGroup) creator.toData();
//todo
if (index == 1) {
combo.setReturnString(true);
} else {
combo.setReturnString(false);
}
}
};
double f = TableLayout.FILL; double f = TableLayout.FILL;
@ -66,17 +56,13 @@ public class CheckBoxGroupDefinePane extends ButtonGroupDefinePane<CheckBoxGroup
double[] columnSize = {p, f}; double[] columnSize = {p, f};
int[][] rowCount = {{1, 1},{1, 1}}; int[][] rowCount = {{1, 1},{1, 1}};
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 10, 7); JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, 10, 7);
panel.setBorder(BorderFactory.createEmptyBorder(0, 0, 5, 0)); panel.setBorder(BorderFactory.createEmptyBorder(0, 0, 10, 0));
return panel; return panel;
} }
@Override @Override
protected void populateSubButtonGroupBean(CheckBoxGroup ob) { protected void populateSubButtonGroupBean(CheckBoxGroup ob) {
if (ob.isReturnString()) { returnType.setSelectedIndex(ob.isReturnString() ? 1 : 0);
returnType.setSelectedIndex(1);
} else {
returnType.setSelectedIndex(0);
}
this.dictPane.populateBean(ob.getDictionary()); this.dictPane.populateBean(ob.getDictionary());
checkbox.setSelected(ob.isChooseAll()); checkbox.setSelected(ob.isChooseAll());
} }
@ -86,6 +72,7 @@ public class CheckBoxGroupDefinePane extends ButtonGroupDefinePane<CheckBoxGroup
@Override @Override
protected CheckBoxGroup updateSubButtonGroupBean() { protected CheckBoxGroup updateSubButtonGroupBean() {
CheckBoxGroup ob = (CheckBoxGroup) creator.toData(); CheckBoxGroup ob = (CheckBoxGroup) creator.toData();
ob.setReturnString(returnType.getSelectedIndex() == 1);
ob.setDictionary(this.dictPane.updateBean()); ob.setDictionary(this.dictPane.updateBean());
ob.setChooseAll(checkbox.isSelected()); ob.setChooseAll(checkbox.isSelected());
return ob; return ob;

23
designer_form/src/com/fr/design/widget/ui/designer/ComboCheckBoxDefinePane.java

@ -2,6 +2,7 @@ package com.fr.design.widget.ui.designer;
import com.fr.design.data.DataCreatorUI; import com.fr.design.data.DataCreatorUI;
import com.fr.design.designer.creator.XCreator; import com.fr.design.designer.creator.XCreator;
import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIHeadGroup;
import com.fr.design.gui.icheckbox.UICheckBox; import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
@ -16,7 +17,7 @@ import java.awt.*;
public class ComboCheckBoxDefinePane extends DictEditorDefinePane<ComboCheckBox> { public class ComboCheckBoxDefinePane extends DictEditorDefinePane<ComboCheckBox> {
private UICheckBox supportTagCheckBox; private UICheckBox supportTagCheckBox;
private UIHeadGroup returnType; private UIButtonGroup returnType;
private UITextField waterMarkDictPane; private UITextField waterMarkDictPane;
private UICheckBox removeRepeatCheckBox; private UICheckBox removeRepeatCheckBox;
@ -40,18 +41,7 @@ public class ComboCheckBoxDefinePane extends DictEditorDefinePane<ComboCheckBox>
supportTagCheckBox = new UICheckBox(Inter.getLocText("Form-SupportTag"), true); supportTagCheckBox = new UICheckBox(Inter.getLocText("Form-SupportTag"), true);
final String[] tabTitles = new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")}; final String[] tabTitles = new String[]{Inter.getLocText("Widget-Array"), Inter.getLocText("String")};
returnType = new UIHeadGroup(tabTitles) { returnType = new UIButtonGroup(tabTitles) ;
@Override
public void tabChanged(int index) {
ComboCheckBox combo = (ComboCheckBox) creator.toData();
//todo
if (index == 1) {
combo.setReturnString(true);
} else {
combo.setReturnString(false);
}
}
};
double f = TableLayout.FILL; double f = TableLayout.FILL;
double p = TableLayout.PREFERRED; double p = TableLayout.PREFERRED;
@ -68,11 +58,7 @@ public class ComboCheckBoxDefinePane extends DictEditorDefinePane<ComboCheckBox>
} }
protected void populateSubDictionaryEditorBean(ComboCheckBox ob){ protected void populateSubDictionaryEditorBean(ComboCheckBox ob){
if (ob.isReturnString()) { returnType.setSelectedIndex(ob.isReturnString() ? 1 : 0);
returnType.setSelectedIndex(1);
} else {
returnType.setSelectedIndex(0);
}
waterMarkDictPane.setText(ob.getWaterMark()); waterMarkDictPane.setText(ob.getWaterMark());
formWidgetValuePane.populate(ob); formWidgetValuePane.populate(ob);
this.supportTagCheckBox.setSelected(ob.isSupportTag()); this.supportTagCheckBox.setSelected(ob.isSupportTag());
@ -81,6 +67,7 @@ public class ComboCheckBoxDefinePane extends DictEditorDefinePane<ComboCheckBox>
protected ComboCheckBox updateSubDictionaryEditorBean(){ protected ComboCheckBox updateSubDictionaryEditorBean(){
ComboCheckBox combo = (ComboCheckBox) creator.toData(); ComboCheckBox combo = (ComboCheckBox) creator.toData();
combo.setReturnString(returnType.getSelectedIndex() == 1);
formWidgetValuePane.update(combo); formWidgetValuePane.update(combo);
combo.setWaterMark(waterMarkDictPane.getText()); combo.setWaterMark(waterMarkDictPane.getText());
combo.setSupportTag(this.supportTagCheckBox.isSelected()); combo.setSupportTag(this.supportTagCheckBox.isSelected());

9
designer_form/src/com/fr/design/widget/ui/designer/DateEditorDefinePane.java

@ -4,6 +4,7 @@ import com.fr.base.FRContext;
import com.fr.base.Formula; import com.fr.base.Formula;
import com.fr.data.core.FormatField; import com.fr.data.core.FormatField;
import com.fr.design.designer.creator.XCreator; import com.fr.design.designer.creator.XCreator;
import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIHeadGroup;
import com.fr.design.gui.icombobox.UIComboBox; import com.fr.design.gui.icombobox.UIComboBox;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
@ -28,7 +29,7 @@ import java.text.SimpleDateFormat;
import java.util.Date; import java.util.Date;
public class DateEditorDefinePane extends DirectWriteEditorDefinePane<DateEditor> { public class DateEditorDefinePane extends DirectWriteEditorDefinePane<DateEditor> {
private UIHeadGroup returnTypeComboBox; private UIButtonGroup returnTypeComboBox;
private DateValuePane startDv; private DateValuePane startDv;
private DateValuePane endDv; private DateValuePane endDv;
private WaterMarkDictPane waterMarkDictPane; private WaterMarkDictPane waterMarkDictPane;
@ -55,11 +56,7 @@ public class DateEditorDefinePane extends DirectWriteEditorDefinePane<DateEditor
fontSizePane = new UISpinner(0, 20, 1, 0); fontSizePane = new UISpinner(0, 20, 1, 0);
JPanel returnTypePane = FRGUIPaneFactory.createBorderLayout_S_Pane(); JPanel returnTypePane = FRGUIPaneFactory.createBorderLayout_S_Pane();
returnTypePane.add(new UILabel(Inter.getLocText("Widget-Date_Selector_Return_Type") + ":"), BorderLayout.WEST); returnTypePane.add(new UILabel(Inter.getLocText("Widget-Date_Selector_Return_Type") + ":"), BorderLayout.WEST);
returnTypeComboBox = new UIHeadGroup(new String[] {Inter.getLocText("Date") , Inter.getLocText("String")}){ returnTypeComboBox = new UIButtonGroup<>(new String[] {Inter.getLocText("Date") , Inter.getLocText("String")});
protected void tabChanged(int newSelectedIndex) {
//todo
}
};
JPanel formatHead = createFormatHead(); JPanel formatHead = createFormatHead();
startDv = new DateValuePane(); startDv = new DateValuePane();

38
designer_form/src/com/fr/design/widget/ui/designer/component/FormWidgetValuePane.java

@ -2,7 +2,7 @@ package com.fr.design.widget.ui.designer.component;
import com.fr.design.constants.LayoutConstants; import com.fr.design.constants.LayoutConstants;
import com.fr.design.editor.editor.*; import com.fr.design.editor.editor.*;
import com.fr.design.gui.ibutton.UIHeadGroup; import com.fr.design.gui.ibutton.UIButtonGroup;
import com.fr.design.mainframe.widget.editors.DataBindingEditor; import com.fr.design.mainframe.widget.editors.DataBindingEditor;
import com.fr.design.mainframe.widget.editors.DataTableEditor; import com.fr.design.mainframe.widget.editors.DataTableEditor;
import com.fr.design.mainframe.widget.editors.ServerDataBindingEditor; import com.fr.design.mainframe.widget.editors.ServerDataBindingEditor;
@ -19,45 +19,47 @@ import java.awt.*;
* Created by ibm on 2017/7/27. * Created by ibm on 2017/7/27.
*/ */
public class FormWidgetValuePane extends JPanel { public class FormWidgetValuePane extends JPanel {
private UIHeadGroup widgetValueHead; private UIButtonGroup widgetValueHead;
private Editor[] editor; private Editor[] editor;
private JPanel customPane;
private CardLayout cardLayout;
public FormWidgetValuePane(Object o, boolean onlyServer) { public FormWidgetValuePane(Object o, boolean onlyServer) {
DataControl widget = (DataControl) o; DataControl widget = (DataControl) o;
editor = createWidgetValueEditor(widget, onlyServer); editor = createWidgetValueEditor(widget, onlyServer);
this.setLayout(new BorderLayout(0, LayoutConstants.VGAP_SMALL)); this.setLayout(new BorderLayout(0, LayoutConstants.VGAP_SMALL));
final CardLayout cardLayout = new CardLayout(); cardLayout = new CardLayout();
final JPanel customPane = new JPanel(cardLayout); customPane = new JPanel(cardLayout);
final String[] tabTitles = new String[editor.length]; final String[] tabTitles = new String[editor.length];
for (int i = 0; i < editor.length; i++) { for (int i = 0; i < editor.length; i++) {
customPane.add(editor[i], editor[i].getName()); customPane.add(editor[i], editor[i].getName());
tabTitles[i] = editor[i].getName(); tabTitles[i] = editor[i].getName();
} }
widgetValueHead = new UIHeadGroup(tabTitles) { widgetValueHead = new UIButtonGroup(tabTitles);
@Override
public void tabChanged(int index) {
//todo
attributeChange(index, customPane, cardLayout, tabTitles);
}
};
this.add(widgetValueHead, BorderLayout.NORTH); this.add(widgetValueHead, BorderLayout.NORTH);
this.add(customPane, BorderLayout.CENTER); this.add(customPane, BorderLayout.CENTER);
} }
public void attributeChange(int index, JPanel customPane, CardLayout cardLayout, String[] tabTitles){ public void attributeChange() {
if (ComparatorUtils.equals(tabTitles[index], Inter.getLocText("FR-Designer_Widget_Field"))) { int index = widgetValueHead.getSelectedIndex();
if (index == -1) {
index = 0;
widgetValueHead.setSelectedIndex(index);
}
if (ComparatorUtils.equals(editor[index].getName(), Inter.getLocText("FR-Designer_Widget_Field"))) {
customPane.setPreferredSize(new Dimension(100, 47)); customPane.setPreferredSize(new Dimension(100, 47));
} else { } else {
customPane.setPreferredSize(new Dimension(100, 20)); customPane.setPreferredSize(new Dimension(100, 20));
} }
cardLayout.show(customPane, tabTitles[index]); cardLayout.show(customPane, editor[index].getName());
} }
/** /**
* 根据类型创建 * 根据类型创建
*
* @param type 类型 * @param type 类型
* @param onlyServer 是否是服务器 * @param onlyServer 是否是服务器
* @return 编辑器 * @return 编辑器
@ -86,6 +88,7 @@ public class FormWidgetValuePane extends JPanel {
/** /**
* 用DataControl构建 * 用DataControl构建
*
* @param data 数据 * @param data 数据
* @param onlyServer 是否是服务器 * @param onlyServer 是否是服务器
* @return 编辑器 * @return 编辑器
@ -101,6 +104,7 @@ public class FormWidgetValuePane extends JPanel {
} }
public void update(DataControl ob) { public void update(DataControl ob) {
attributeChange();
int index = widgetValueHead.getSelectedIndex(); int index = widgetValueHead.getSelectedIndex();
Editor e = editor[index]; Editor e = editor[index];
Object value = e.getValue(); Object value = e.getValue();
@ -109,9 +113,7 @@ public class FormWidgetValuePane extends JPanel {
public void populate(DataControl ob) { public void populate(DataControl ob) {
WidgetValue widgetValue = ob.getWidgetValue(); WidgetValue widgetValue = ob.getWidgetValue();
if(widgetValue == null){ if (widgetValue != null) {
return;
}
for (int i = 0; i < editor.length; i++) { for (int i = 0; i < editor.length; i++) {
if (editor[i].accept(widgetValue.getValue())) { if (editor[i].accept(widgetValue.getValue())) {
setCardValue(i, widgetValue.getValue()); setCardValue(i, widgetValue.getValue());
@ -119,6 +121,8 @@ public class FormWidgetValuePane extends JPanel {
} }
} }
} }
attributeChange();
}
private void setCardValue(int i, Object object) { private void setCardValue(int i, Object object) {
widgetValueHead.setSelectedIndex(i); widgetValueHead.setSelectedIndex(i);

2
designer_form/src/com/fr/design/widget/ui/designer/component/TabFitLayoutBackgroundPane.java

@ -26,6 +26,7 @@ public class TabFitLayoutBackgroundPane extends BackgroundCompPane<WTabFitLayout
wTabFitLayout.setOverBackground((Background) overBackgroundEditor.getValue()); wTabFitLayout.setOverBackground((Background) overBackgroundEditor.getValue());
wTabFitLayout.setClickBackground((Background)clickBackgroundEditor.getValue()); wTabFitLayout.setClickBackground((Background)clickBackgroundEditor.getValue());
} }
switchCard();
} }
public void populate(WTabFitLayout wTabFitLayout){ public void populate(WTabFitLayout wTabFitLayout){
@ -40,6 +41,7 @@ public class TabFitLayoutBackgroundPane extends BackgroundCompPane<WTabFitLayout
overBackgroundEditor.setValue(wTabFitLayout.getOverBackground()); overBackgroundEditor.setValue(wTabFitLayout.getOverBackground());
clickBackgroundEditor.setValue(wTabFitLayout.getClickBackground()); clickBackgroundEditor.setValue(wTabFitLayout.getClickBackground());
} }
switchCard();
} }
protected String title4PopupWindow() { protected String title4PopupWindow() {

Loading…
Cancel
Save