diff --git a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java index 6f9383e4d4..b2519271b0 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java @@ -16,6 +16,7 @@ import com.fr.design.actions.edit.RedoAction; import com.fr.design.actions.edit.UndoAction; import com.fr.design.actions.file.SaveAsTemplateAction; import com.fr.design.actions.file.SaveTemplateAction; +import com.fr.design.actions.file.WebPreviewUtils; import com.fr.design.constants.UIConstants; import com.fr.design.designer.TargetComponent; import com.fr.design.dialog.InformationWarnPane; @@ -1102,6 +1103,8 @@ public abstract class JTemplate> * @param provider 预览模式 */ public void previewMenuActionPerformed(PreviewProvider provider) { + setPreviewType(provider); + WebPreviewUtils.preview(this, provider); } diff --git a/designer-base/src/main/java/com/fr/design/preview/FormPreview.java b/designer-base/src/main/java/com/fr/design/preview/FormPreview.java index d6206a2c0a..8522d67734 100644 --- a/designer-base/src/main/java/com/fr/design/preview/FormPreview.java +++ b/designer-base/src/main/java/com/fr/design/preview/FormPreview.java @@ -1,7 +1,6 @@ package com.fr.design.preview; import com.fr.design.fun.impl.AbstractPreviewProvider; -import com.fr.locale.InterProviderFactory; /** @@ -13,7 +12,7 @@ public class FormPreview extends AbstractPreviewProvider { @Override public String nameForPopupItem() { - return InterProviderFactory.getProvider().getLocText("Fine-Design_Form_M_Form_Preview"); + return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Form_M_Form_Preview"); } @Override diff --git a/designer-base/src/main/java/com/fr/design/preview/MobilePreview.java b/designer-base/src/main/java/com/fr/design/preview/MobilePreview.java index 4ab9425010..ca75e39ac3 100644 --- a/designer-base/src/main/java/com/fr/design/preview/MobilePreview.java +++ b/designer-base/src/main/java/com/fr/design/preview/MobilePreview.java @@ -1,7 +1,6 @@ package com.fr.design.preview; import com.fr.design.fun.impl.AbstractPreviewProvider; -import com.fr.general.Inter; import java.util.HashMap; import java.util.Map; @@ -16,7 +15,7 @@ public class MobilePreview extends AbstractPreviewProvider { @Override public String nameForPopupItem() { - return Inter.getLocText("Fine-Design_Mobile_Preview"); + return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Mobile_Preview"); } @Override diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java b/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java index e60fa59785..bfc01d0bf9 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java @@ -10,7 +10,6 @@ import com.fr.design.DesignModelAdapter; import com.fr.design.ExtraDesignClassManager; import com.fr.design.actions.AllowAuthorityEditAction; import com.fr.design.actions.ExitAuthorityEditAction; -import com.fr.design.actions.file.WebPreviewUtils; import com.fr.design.actions.file.export.CSVExportAction; import com.fr.design.actions.file.export.EmbeddedExportExportAction; import com.fr.design.actions.file.export.ExcelExportAction; @@ -924,8 +923,7 @@ public class JWorkBook extends JTemplate { */ @Override public void previewMenuActionPerformed(PreviewProvider provider) { - setPreviewType(provider); - WebPreviewUtils.preview(this, provider); + super.previewMenuActionPerformed(provider); } /**