From ad82af29f5d484c4d47763509481ece039fa595c Mon Sep 17 00:00:00 2001 From: plough Date: Tue, 15 May 2018 11:33:58 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-7867=20=E5=88=A0=E9=99=A4=E4=B8=8D?= =?UTF-8?q?=E5=9C=A8i18n=E4=B8=8B=E7=9A=84=E5=9B=BD=E9=99=85=E5=8C=96?= =?UTF-8?q?=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ui/rsyntaxtextarea/RSyntaxTextAreaEditorKit.java | 7 ++----- .../design/gui/syntax/ui/rtextarea/RUndoManager.java | 10 ++++------ 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/designer-base/src/com/fr/design/gui/syntax/ui/rsyntaxtextarea/RSyntaxTextAreaEditorKit.java b/designer-base/src/com/fr/design/gui/syntax/ui/rsyntaxtextarea/RSyntaxTextAreaEditorKit.java index 560239150a..a8b7f0c218 100644 --- a/designer-base/src/com/fr/design/gui/syntax/ui/rsyntaxtextarea/RSyntaxTextAreaEditorKit.java +++ b/designer-base/src/com/fr/design/gui/syntax/ui/rsyntaxtextarea/RSyntaxTextAreaEditorKit.java @@ -24,6 +24,7 @@ import com.fr.design.gui.syntax.ui.rtextarea.IconRowHeader; import com.fr.design.gui.syntax.ui.rtextarea.RecordableTextAction; import com.fr.design.gui.syntax.ui.rtextarea.RTextArea; import com.fr.design.gui.syntax.ui.rtextarea.RTextAreaEditorKit; +import com.fr.general.Inter; /** @@ -72,10 +73,6 @@ public class RSyntaxTextAreaEditorKit extends RTextAreaEditorKit { public static final String rstaToggleCommentAction = "RSTA.ToggleCommentAction"; public static final String rstaToggleCurrentFoldAction = "RSTA.ToggleCurrentFoldAction"; - private static final String MSG = "com.fr.design.gui.syntax.ui.rsyntaxtextarea.RSyntaxTextArea"; - private static final ResourceBundle msg = ResourceBundle.getBundle(MSG); - - /** * The actions that RSyntaxTextAreaEditorKit adds to those of * RTextAreaEditorKit. @@ -163,7 +160,7 @@ public class RSyntaxTextAreaEditorKit extends RTextAreaEditorKit { * @return The localized text. */ public static String getString(String key) { - return msg.getString(key); + return Inter.getLocText(key); } diff --git a/designer-base/src/com/fr/design/gui/syntax/ui/rtextarea/RUndoManager.java b/designer-base/src/com/fr/design/gui/syntax/ui/rtextarea/RUndoManager.java index 4eeef2d354..193230d08c 100644 --- a/designer-base/src/com/fr/design/gui/syntax/ui/rtextarea/RUndoManager.java +++ b/designer-base/src/com/fr/design/gui/syntax/ui/rtextarea/RUndoManager.java @@ -8,6 +8,8 @@ */ package com.fr.design.gui.syntax.ui.rtextarea; +import com.fr.general.Inter; + import java.util.ResourceBundle; import javax.swing.Action; import javax.swing.UIManager; @@ -40,9 +42,6 @@ public class RUndoManager extends UndoManager { private int internalAtomicEditDepth; - private static final String MSG = "com.fr.design.gui.syntax.ui.rtextarea.RTextArea"; - - /** * Constructor. * @@ -50,9 +49,8 @@ public class RUndoManager extends UndoManager { */ public RUndoManager(RTextArea textArea) { this.textArea = textArea; - ResourceBundle msg = ResourceBundle.getBundle(MSG); - cantUndoText = msg.getString("Action.CantUndo.Name"); - cantRedoText = msg.getString("Action.CantRedo.Name"); + cantUndoText = Inter.getLocText("Action.CantUndo.Name"); + cantRedoText = Inter.getLocText("Action.CantRedo.Name"); }