Browse Source

Pull request #11940: REPORT-90316 单元格控件的移动端属性

Merge in DESIGN/design from ~CORAL.CHEN/design:feature/x to feature/x

* commit 'fbb07da941e3495bb1ac33adc9305ecf8a1161c1':
  REPORT-90316 补充注释
  REPORT-90316 单元格控件的移动端属性
feature/x
Coral.Chen-张晨 2 years ago
parent
commit
276f135bb1
  1. 15
      designer-form/src/main/java/com/fr/design/designer/properties/mobile/TextEditorMobilePropertyUI.java
  2. 10
      designer-form/src/main/java/com/fr/design/widget/ui/designer/mobile/TextEditorMobileDefinePane.java
  3. 13
      designer-realize/src/main/java/com/fr/design/widget/WidgetMobilePaneFactory.java
  4. 41
      designer-realize/src/main/java/com/fr/design/widget/ui/mobile/NumberEditorMobilePane.java
  5. 42
      designer-realize/src/main/java/com/fr/design/widget/ui/mobile/PasswordMobilePane.java
  6. 38
      designer-realize/src/main/java/com/fr/design/widget/ui/mobile/ScanCodeMobilePane.java
  7. 42
      designer-realize/src/main/java/com/fr/design/widget/ui/mobile/TextAreaMobilePane.java
  8. 59
      designer-realize/src/main/java/com/fr/design/widget/ui/mobile/TextEditorMobilePane.java

15
designer-form/src/main/java/com/fr/design/designer/properties/mobile/ScanCodeMobilePropertyUI.java → designer-form/src/main/java/com/fr/design/designer/properties/mobile/TextEditorMobilePropertyUI.java

@ -5,13 +5,20 @@ import com.fr.design.designer.creator.XTextEditor;
import com.fr.design.dialog.BasicPane;
import com.fr.design.fun.impl.AbstractWidgetPropertyUIProvider;
import com.fr.design.gui.itable.AbstractPropertyTable;
import com.fr.design.widget.ui.designer.mobile.ScanCodeMobileDefinePane;
import com.fr.design.widget.ui.designer.mobile.TextEditorMobileDefinePane;
public class ScanCodeMobilePropertyUI extends AbstractWidgetPropertyUIProvider {
/**
* 文本控件
*
* @author Coral.Chen
* @since 11.0
* Created on 2023/3/30
*/
public class TextEditorMobilePropertyUI extends AbstractWidgetPropertyUIProvider {
private XCreator xCreator;
public ScanCodeMobilePropertyUI(XTextEditor xTextEditor) {
public TextEditorMobilePropertyUI(XTextEditor xTextEditor) {
this.xCreator = xTextEditor;
}
@ -22,7 +29,7 @@ public class ScanCodeMobilePropertyUI extends AbstractWidgetPropertyUIProvider {
@Override
public BasicPane createWidgetAttrPane() {
return new ScanCodeMobileDefinePane(xCreator);
return new TextEditorMobileDefinePane(xCreator);
}
@Override

10
designer-form/src/main/java/com/fr/design/widget/ui/designer/mobile/ScanCodeMobileDefinePane.java → designer-form/src/main/java/com/fr/design/widget/ui/designer/mobile/TextEditorMobileDefinePane.java

@ -10,17 +10,21 @@ import com.fr.form.ui.TextEditor;
import javax.swing.JPanel;
/**
* 文本控件移动端属性
* 输入方式
* 输入框属性
*
* @author hades
* @since 11.0
* Created on 2018/11/27
*/
public class ScanCodeMobileDefinePane extends BaseTextEditorMobileDefinePane {
public class TextEditorMobileDefinePane extends BaseTextEditorMobileDefinePane {
/**
* 输入方式
*/
private MobileTextFieldInputSettingPane inputSettingPane;
public ScanCodeMobileDefinePane(XCreator xCreator) {
public TextEditorMobileDefinePane(XCreator xCreator) {
super(xCreator);
}

13
designer-realize/src/main/java/com/fr/design/widget/WidgetMobilePaneFactory.java

@ -4,8 +4,14 @@ import com.fr.design.ExtraDesignClassManager;
import com.fr.design.fun.CellWidgetOptionProvider;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.mobile.MultiFileEditorMobilePane;
import com.fr.design.widget.ui.mobile.ScanCodeMobilePane;
import com.fr.design.widget.ui.mobile.NumberEditorMobilePane;
import com.fr.design.widget.ui.mobile.PasswordMobilePane;
import com.fr.design.widget.ui.mobile.TextAreaMobilePane;
import com.fr.design.widget.ui.mobile.TextEditorMobilePane;
import com.fr.form.ui.MultiFileEditor;
import com.fr.form.ui.NumberEditor;
import com.fr.form.ui.Password;
import com.fr.form.ui.TextArea;
import com.fr.form.ui.TextEditor;
import com.fr.form.ui.Widget;
import com.fr.general.GeneralContext;
@ -28,7 +34,10 @@ public class WidgetMobilePaneFactory {
static {
mobilePaneMap.put(MultiFileEditor.class, MultiFileEditorMobilePane.class);
mobilePaneMap.put(TextEditor.class, ScanCodeMobilePane.class);
mobilePaneMap.put(TextEditor.class, TextEditorMobilePane.class);
mobilePaneMap.put(TextArea.class, TextAreaMobilePane.class);
mobilePaneMap.put(NumberEditor.class, NumberEditorMobilePane.class);
mobilePaneMap.put(Password.class, PasswordMobilePane.class);
mobilePluginPaneMap.putAll(ExtraDesignClassManager.getInstance().getCellWidgetMobileOptionsMap());
GeneralContext.listenPluginRunningChanged(new PluginEventListener() {

41
designer-realize/src/main/java/com/fr/design/widget/ui/mobile/NumberEditorMobilePane.java

@ -0,0 +1,41 @@
package com.fr.design.widget.ui.mobile;
import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextEditSettingPane;
import com.fr.form.ui.NumberEditor;
import com.fr.form.ui.Widget;
import java.awt.BorderLayout;
/**
* 数字控件移动端属性
*
* @author Coral.Chen
* @since 11.0
* Created on 2023/4/11
*/
public class NumberEditorMobilePane extends WidgetMobilePane {
private MobileTextEditSettingPane textSettingPane;
@Override
protected void init() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
textSettingPane = new MobileTextEditSettingPane();
this.add(new UIExpandablePane(Toolkit.i18nText("Fine-Design_Report_Advanced"), 280, 20, textSettingPane), BorderLayout.NORTH);
}
@Override
public void populate(Widget widget) {
NumberEditor numberEditor = (NumberEditor) widget;
textSettingPane.populateBean(numberEditor.getMobileTextEditAttr());
}
@Override
public void update(Widget widget) {
NumberEditor numberEditor = (NumberEditor) widget;
textSettingPane.updateBean(numberEditor.getMobileTextEditAttr());
}
}

42
designer-realize/src/main/java/com/fr/design/widget/ui/mobile/PasswordMobilePane.java

@ -0,0 +1,42 @@
package com.fr.design.widget.ui.mobile;
import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.designer.mobile.component.MobilePasswordEditSettingPane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextEditSettingPane;
import com.fr.form.ui.TextEditor;
import com.fr.form.ui.Widget;
import java.awt.BorderLayout;
/**
* 密码控件移动端属性
*
* @author Coral.Chen
* @since 11.0
* Created on 2023/4/11
*/
public class PasswordMobilePane extends WidgetMobilePane {
private MobileTextEditSettingPane textSettingPane;
@Override
protected void init() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
textSettingPane = new MobilePasswordEditSettingPane();
this.add(new UIExpandablePane(Toolkit.i18nText("Fine-Design_Report_Advanced"), 280, 20, textSettingPane), BorderLayout.NORTH);
}
@Override
public void populate(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
textSettingPane.populateBean(textEditor.getMobileTextEditAttr());
}
@Override
public void update(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
textSettingPane.updateBean(textEditor.getMobileTextEditAttr());
}
}

38
designer-realize/src/main/java/com/fr/design/widget/ui/mobile/ScanCodeMobilePane.java

@ -1,38 +0,0 @@
package com.fr.design.widget.ui.mobile;
import com.fr.base.mobile.MobileScanCodeAttr;
import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextFieldInputSettingPane;
import com.fr.form.ui.TextEditor;
import com.fr.form.ui.Widget;
import java.awt.BorderLayout;
public class ScanCodeMobilePane extends WidgetMobilePane {
private MobileTextFieldInputSettingPane settingPane;
@Override
protected void init() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
settingPane = new MobileTextFieldInputSettingPane();
this.add(new UIExpandablePane(Toolkit.i18nText("Fine-Design_Report_Advanced"), 280, 20, settingPane), BorderLayout.NORTH);
}
@Override
public void populate(Widget widget) {
MobileScanCodeAttr mobileScanCodeAttr = ((TextEditor) widget).getMobileScanCodeAttr();
settingPane.populateBean(mobileScanCodeAttr);
}
@Override
public void update(Widget widget) {
MobileScanCodeAttr mobileScanCodeAttr = ((TextEditor) widget).getMobileScanCodeAttr();
settingPane.updateBean(mobileScanCodeAttr);
}
}

42
designer-realize/src/main/java/com/fr/design/widget/ui/mobile/TextAreaMobilePane.java

@ -0,0 +1,42 @@
package com.fr.design.widget.ui.mobile;
import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextAreaSettingPane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextEditSettingPane;
import com.fr.form.ui.TextEditor;
import com.fr.form.ui.Widget;
import java.awt.BorderLayout;
/**
* 文本域控件移动端属性
*
* @author Coral.Chen
* @since 11.0
* Created on 2023/4/11
*/
public class TextAreaMobilePane extends WidgetMobilePane {
private MobileTextEditSettingPane textSettingPane;
@Override
protected void init() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
textSettingPane = new MobileTextAreaSettingPane();
this.add(new UIExpandablePane(Toolkit.i18nText("Fine-Design_Report_Advanced"), 280, 20, textSettingPane), BorderLayout.NORTH);
}
@Override
public void populate(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
textSettingPane.populateBean(textEditor.getMobileTextEditAttr());
}
@Override
public void update(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
textSettingPane.updateBean(textEditor.getMobileTextEditAttr());
}
}

59
designer-realize/src/main/java/com/fr/design/widget/ui/mobile/TextEditorMobilePane.java

@ -0,0 +1,59 @@
package com.fr.design.widget.ui.mobile;
import com.fr.design.foldablepane.UIExpandablePane;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.widget.mobile.WidgetMobilePane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextEditSettingPane;
import com.fr.design.widget.ui.designer.mobile.component.MobileTextFieldInputSettingPane;
import com.fr.form.ui.TextEditor;
import com.fr.form.ui.Widget;
import javax.swing.JPanel;
import java.awt.BorderLayout;
/**
* 文本控件移动端属性面板
*
* @author Coral.Chen
* @since 11.0
* Created on 2023/4/12
*/
public class TextEditorMobilePane extends WidgetMobilePane {
/**
* 输入方式
*/
private MobileTextFieldInputSettingPane settingPane;
/**
* 输入框属性配置
*/
private MobileTextEditSettingPane textSettingPane;
@Override
protected void init() {
JPanel container = FRGUIPaneFactory.createVerticalFlowLayout_S_Pane(true);
this.setLayout(FRGUIPaneFactory.createBorderLayout());
settingPane = new MobileTextFieldInputSettingPane();
textSettingPane = new MobileTextEditSettingPane();
container.add(settingPane);
container.add(textSettingPane);
this.add(new UIExpandablePane(Toolkit.i18nText("Fine-Design_Report_Advanced"), 280, 20, container), BorderLayout.NORTH);
}
@Override
public void populate(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
settingPane.populateBean(textEditor.getMobileScanCodeAttr());
textSettingPane.populateBean(textEditor.getMobileTextEditAttr());
}
@Override
public void update(Widget widget) {
TextEditor textEditor = (TextEditor) widget;
settingPane.updateBean(textEditor.getMobileScanCodeAttr());
textSettingPane.updateBean(textEditor.getMobileTextEditAttr());
}
}
Loading…
Cancel
Save