Browse Source

REPORT-19465 【匹配移动端】模板级全局控制缩放等

research/10.0
Hades 5 years ago
parent
commit
bc5f6a6cf3
  1. 5
      designer-form/src/main/java/com/fr/design/form/mobile/FormMobileOthersPane.java
  2. 7
      designer-realize/src/main/java/com/fr/design/report/mobile/MobileOthersPane.java

5
designer-form/src/main/java/com/fr/design/form/mobile/FormMobileOthersPane.java

@ -18,6 +18,7 @@ public class FormMobileOthersPane extends BasicBeanPane<FormMobileAttr> {
private MobileRadioCheckPane appearRefreshCheckPane; // 页面再现时刷新 private MobileRadioCheckPane appearRefreshCheckPane; // 页面再现时刷新
private MobileRadioCheckPane promptWhenLeaveWithoutSubmitCheckPane; // 数据未提交离开提示 private MobileRadioCheckPane promptWhenLeaveWithoutSubmitCheckPane; // 数据未提交离开提示
private MobileRadioCheckPane allowDoubleClickOrZoomCheckPane; // 允许双击/双指缩放
public FormMobileOthersPane() { public FormMobileOthersPane() {
this.initComponents(); this.initComponents();
@ -32,6 +33,8 @@ public class FormMobileOthersPane extends BasicBeanPane<FormMobileAttr> {
contentPane.add(appearRefreshCheckPane, BorderLayout.WEST); contentPane.add(appearRefreshCheckPane, BorderLayout.WEST);
promptWhenLeaveWithoutSubmitCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Prompt_When_Leave_Without_Submit")); promptWhenLeaveWithoutSubmitCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Prompt_When_Leave_Without_Submit"));
contentPane.add(promptWhenLeaveWithoutSubmitCheckPane, BorderLayout.CENTER); contentPane.add(promptWhenLeaveWithoutSubmitCheckPane, BorderLayout.CENTER);
allowDoubleClickOrZoomCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("允许双击/双指缩放"));
contentPane.add(allowDoubleClickOrZoomCheckPane, BorderLayout.EAST);
borderPane.add(contentPane); borderPane.add(contentPane);
this.add(borderPane); this.add(borderPane);
} }
@ -43,6 +46,7 @@ public class FormMobileOthersPane extends BasicBeanPane<FormMobileAttr> {
} }
this.appearRefreshCheckPane.populateBean(ob.isAppearRefresh()); this.appearRefreshCheckPane.populateBean(ob.isAppearRefresh());
this.promptWhenLeaveWithoutSubmitCheckPane.populateBean(ob.isPromptWhenLeaveWithoutSubmit()); this.promptWhenLeaveWithoutSubmitCheckPane.populateBean(ob.isPromptWhenLeaveWithoutSubmit());
this.allowDoubleClickOrZoomCheckPane.populateBean(ob.isAllowDoubleClickOrZoom());
} }
@Override @Override
@ -55,6 +59,7 @@ public class FormMobileOthersPane extends BasicBeanPane<FormMobileAttr> {
if(mobileAttr != null) { if(mobileAttr != null) {
mobileAttr.setAppearRefresh(this.appearRefreshCheckPane.updateBean()); mobileAttr.setAppearRefresh(this.appearRefreshCheckPane.updateBean());
mobileAttr.setPromptWhenLeaveWithoutSubmit(this.promptWhenLeaveWithoutSubmitCheckPane.updateBean()); mobileAttr.setPromptWhenLeaveWithoutSubmit(this.promptWhenLeaveWithoutSubmitCheckPane.updateBean());
mobileAttr.setAllowDoubleClickOrZoom(this.allowDoubleClickOrZoomCheckPane.updateBean());
} }
} }

7
designer-realize/src/main/java/com/fr/design/report/mobile/MobileOthersPane.java

@ -18,6 +18,9 @@ public class MobileOthersPane extends BasicBeanPane<ElementCaseMobileAttr> {
private MobileRadioCheckPane appearRefreshCheckPane; // 页面再现时刷新 private MobileRadioCheckPane appearRefreshCheckPane; // 页面再现时刷新
// 允许双击/双指缩放
private MobileRadioCheckPane allowDoubleClickOrZoomCheckPane;
public MobileOthersPane() { public MobileOthersPane() {
this.initComponents(); this.initComponents();
} }
@ -29,6 +32,8 @@ public class MobileOthersPane extends BasicBeanPane<ElementCaseMobileAttr> {
contentPane.setBorder(BorderFactory.createEmptyBorder(0, IntervalConstants.INTERVAL_L1, 0, 0)); contentPane.setBorder(BorderFactory.createEmptyBorder(0, IntervalConstants.INTERVAL_L1, 0, 0));
appearRefreshCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Appear_Refresh")); appearRefreshCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Appear_Refresh"));
contentPane.add(appearRefreshCheckPane, BorderLayout.WEST); contentPane.add(appearRefreshCheckPane, BorderLayout.WEST);
allowDoubleClickOrZoomCheckPane = new MobileRadioCheckPane(com.fr.design.i18n.Toolkit.i18nText("允许双击/双指缩放"));
contentPane.add(allowDoubleClickOrZoomCheckPane, BorderLayout.CENTER);
borderPane.add(contentPane); borderPane.add(contentPane);
this.add(borderPane); this.add(borderPane);
} }
@ -39,6 +44,7 @@ public class MobileOthersPane extends BasicBeanPane<ElementCaseMobileAttr> {
ob = new ElementCaseMobileAttr(); ob = new ElementCaseMobileAttr();
} }
this.appearRefreshCheckPane.populateBean(ob.isAppearRefresh()); this.appearRefreshCheckPane.populateBean(ob.isAppearRefresh());
this.allowDoubleClickOrZoomCheckPane.populateBean(ob.isAllowDoubleClickOrZoom());
} }
@Override @Override
@ -50,6 +56,7 @@ public class MobileOthersPane extends BasicBeanPane<ElementCaseMobileAttr> {
public void updateBean(ElementCaseMobileAttr mobileAttr) { public void updateBean(ElementCaseMobileAttr mobileAttr) {
if(mobileAttr != null) { if(mobileAttr != null) {
mobileAttr.setAppearRefresh(this.appearRefreshCheckPane.updateBean()); mobileAttr.setAppearRefresh(this.appearRefreshCheckPane.updateBean());
mobileAttr.setAllowDoubleClickOrZoom(this.allowDoubleClickOrZoomCheckPane.updateBean());
} }
} }

Loading…
Cancel
Save