Browse Source

模板web属性-打印机

persist/11.0-arabic
obo 6 months ago
parent
commit
bd7ac79a83
  1. 5
      designer-base/src/main/java/com/fr/design/dialog/UIDialog.java
  2. 2
      designer-realize/src/main/java/com/fr/design/webattr/ReportServerPrinterPane.java
  3. 11
      designer-realize/src/main/java/com/fr/design/webattr/ServerPrinterPane.java

5
designer-base/src/main/java/com/fr/design/dialog/UIDialog.java

@ -1,5 +1,6 @@
package com.fr.design.dialog;
import com.fr.base.i18n.BidiUtils;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.utils.gui.GUICoreUtils;
@ -94,8 +95,8 @@ public abstract class UIDialog extends JDialog {
private JPanel createControlButtonPane() {
JPanel controlPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
JPanel buttonsPane = new JPanel(new FlowLayout(FlowLayout.LEFT, 10, 0));
controlPane.add(buttonsPane, BorderLayout.EAST);
JPanel buttonsPane = new JPanel(new FlowLayout(BidiUtils.rtl() ? FlowLayout.RIGHT : FlowLayout.LEFT, 10, 0));
controlPane.add(buttonsPane, BidiUtils.rtl() ? BorderLayout.WEST : BorderLayout.EAST);
//增加一个自定义按钮, 可以用于eg: 设为全局配置
addCustomButton(buttonsPane);

2
designer-realize/src/main/java/com/fr/design/webattr/ReportServerPrinterPane.java

@ -7,6 +7,7 @@ package com.fr.design.webattr;
import javax.swing.BorderFactory;
import javax.swing.JPanel;
import com.fr.base.i18n.BidiUtils;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.report.web.Printer;
/**
@ -26,6 +27,7 @@ public class ReportServerPrinterPane extends JPanel {
this.setBorder(BorderFactory.createEmptyBorder(6, 2, 4, 2));
serverPrinterPane = new ServerPrinterPane();
this.add(serverPrinterPane);
BidiUtils.applyOrientationByLocale(this);
}
public void populate(Printer printer) {

11
designer-realize/src/main/java/com/fr/design/webattr/ServerPrinterPane.java

@ -4,6 +4,7 @@
package com.fr.design.webattr;
import com.fr.base.BaseUtils;
import com.fr.base.i18n.BidiUtils;
import com.fr.design.dialog.BasicDialog;
import com.fr.design.dialog.BasicPane;
import com.fr.design.dialog.DialogActionAdapter;
@ -141,7 +142,8 @@ public class ServerPrinterPane extends BasicPane {
}
}
});
printerDialog.setTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_Add_Printer") + "...");
printerDialog.setTitle(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_Add_Printer"), "..."));
BidiUtils.applyOrientationByLocale(printerDialog);
printerDialog.setVisible(true);
}
};
@ -262,7 +264,8 @@ public class ServerPrinterPane extends BasicPane {
}
});
printersPane.populate(printerList.getSelectedValue().toString());
printerDialog.setTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_Edit_Printer") + "...");
printerDialog.setTitle(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_Edit_Printer"), "..."));
BidiUtils.applyOrientationByLocale(printerDialog);
printerDialog.setVisible(true);
}
public void populate(Printer printer) {
@ -320,7 +323,7 @@ public class ServerPrinterPane extends BasicPane {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
this.setBorder(BorderFactory.createEmptyBorder(20, 5, 0, 0));
JPanel centerPane = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane();
centerPane.add(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Printer") + ":"), BorderLayout.WEST);
centerPane.add(new UILabel(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Printer"), ":")), BorderLayout.WEST);
DefaultComboBoxModel printerComboModel = new DefaultComboBoxModel();
@ -344,7 +347,7 @@ public class ServerPrinterPane extends BasicPane {
public void checkValid() throws Exception {
String printerName = printerCombo.getSelectedItem().toString();
if (StringUtils.isBlank(printerName)) {
throw new Exception(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_The_Name_Of_Printer_Cannot_Be_Null") + ".");
throw new Exception(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_ReportServerP_The_Name_Of_Printer_Cannot_Be_Null"), "."));
}
}

Loading…
Cancel
Save