diff options
author | Noel Grandin <noel@peralex.com> | 2014-08-21 08:24:17 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-10-07 13:20:03 +0200 |
commit | 81968336ea6433293c603110a75bd13d5898c0eb (patch) | |
tree | c4bc0f45710302f3bd6734388ae9ff01d59c68ad /scripting | |
parent | f9be44340a1fbabb67c7a33d8c9b4766a56c1fde (diff) |
java: use equalsIgnoreCase() instead of toLowerCase().equals()
Change-Id: I8f4afc7e15a9d85d99ea80edbbbd2b507b254ddc
Diffstat (limited to 'scripting')
3 files changed, 5 insertions, 4 deletions
diff --git a/scripting/java/org/openoffice/idesupport/CommandLineTools.java b/scripting/java/org/openoffice/idesupport/CommandLineTools.java index 522828ec2f49..5b9050cfd621 100644 --- a/scripting/java/org/openoffice/idesupport/CommandLineTools.java +++ b/scripting/java/org/openoffice/idesupport/CommandLineTools.java @@ -187,7 +187,7 @@ public class CommandLineTools { StringTokenizer tokenizer = new StringTokenizer(language, "="); this.language = tokenizer.nextToken(); - if (this.language.toLowerCase().equals("java")) { + if (this.language.equalsIgnoreCase("java")) { this.finder = JavaFinder.getInstance(); return; } diff --git a/scripting/java/org/openoffice/idesupport/ui/MethodPanel.java b/scripting/java/org/openoffice/idesupport/ui/MethodPanel.java index 1d0fec35ce82..9bedf5184c34 100644 --- a/scripting/java/org/openoffice/idesupport/ui/MethodPanel.java +++ b/scripting/java/org/openoffice/idesupport/ui/MethodPanel.java @@ -88,7 +88,7 @@ public class MethodPanel extends JPanel { if (language == null) finder = JavaFinder.getInstance(classpath); - else if (language.toLowerCase().equals("beanshell")) + else if (language.equalsIgnoreCase("beanshell")) finder = new ExtensionFinder(language, new String[] {".bsh"}); else finder = JavaFinder.getInstance(classpath); diff --git a/scripting/java/org/openoffice/netbeans/modules/office/loader/ParcelContentsFolder.java b/scripting/java/org/openoffice/netbeans/modules/office/loader/ParcelContentsFolder.java index 9243df8c7341..7ac5ce14069a 100644 --- a/scripting/java/org/openoffice/netbeans/modules/office/loader/ParcelContentsFolder.java +++ b/scripting/java/org/openoffice/netbeans/modules/office/loader/ParcelContentsFolder.java @@ -75,9 +75,10 @@ public class ParcelContentsFolder extends DataFolder { public static void createEmptyScript(DataFolder parent, String language) { String sourceFile = "Templates/OfficeScripting/EmptyScript/Empty"; - if (language.toLowerCase().equals("java")) { + if (language.equalsIgnoreCase("java")) { sourceFile += ".java"; - } else if (language.toLowerCase().equals("beanshell")) { + } + else if (language.equalsIgnoreCase("beanshell")) { sourceFile += ".bsh"; } else { NotifyDescriptor d = new NotifyDescriptor.Message( |